1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-11 00:54:49 +02:00

Query optimization.

This commit is contained in:
Cameron
2015-05-10 12:02:32 -07:00
parent 29ddbe09e8
commit d85bc31932
3 changed files with 479 additions and 473 deletions

View File

@@ -540,6 +540,8 @@ class plugin_forum_view_shortcodes extends e_shortcode
$text .= "<li role='presentation' class='divider'> </li>";
$type = ($this->postInfo['thread_start']) ? 'thread' : 'Post';
// print_a($this->postInfo);
if ((USER && $this->postInfo['post_user'] != USERID && $this->thread->threadInfo['thread_active']))
{
@@ -550,7 +552,8 @@ class plugin_forum_view_shortcodes extends e_shortcode
}
// only show delete button when post is not the initial post of the topic
if(!$this->forum->threadDetermineInitialPost($this->postInfo['post_id']))
// if(!$this->forum->threadDetermineInitialPost($this->postInfo['post_id']))
if(empty($this->postInfo['thread_start']))
{
$text .= "<li class='text-right'><a href='".e_REQUEST_URI."' data-forum-action='deletepost' data-forum-post='".$this->postInfo['post_id']."'>".LAN_DELETE." ".$tp->toGlyph('trash')."</a></li>";
}