Index: branches/5.2.x/units/poll_comments/poll_comment_eh.php =================================================================== diff -u -N -r14848 -r14985 --- branches/5.2.x/units/poll_comments/poll_comment_eh.php (.../poll_comment_eh.php) (revision 14848) +++ branches/5.2.x/units/poll_comments/poll_comment_eh.php (.../poll_comment_eh.php) (revision 14985) @@ -1,6 +1,6 @@ Array('self' => true, 'subitem' => true,), - 'OnItemBuild' => Array('self' => true, 'subitem' => true,), - ); + + $permissions = Array ( + 'OnCreate' => Array ('self' => true, 'subitem' => true,), + 'OnItemBuild' => Array ('self' => true, 'subitem' => true,), + ); + $this->permMapping = array_merge($this->permMapping, $permissions); } @@ -58,16 +63,18 @@ * @access protected * @see kDBEventHandler::OnListBuild() */ - protected function SetCustomQuery(&$event) + protected function SetCustomQuery(kEvent &$event) { - if ($this->Application->isAdminUser) { - return ; + parent::SetCustomQuery($event); + + if ( $this->Application->isAdminUser ) { + return; } $object =& $event->getObject(); /* @var $object kDBList */ - $object->addFilter('comment_status', '(%1$s.Status = ' .STATUS_ACTIVE. ')'); + $object->addFilter('comment_status', '%1$s.Status = ' . STATUS_ACTIVE); } /**