Merge "Spellchecked /includes directory"
[lhc/web/wiklou.git] / includes / specials / SpecialLog.php
index 8e4205c..4fc0f6e 100644 (file)
@@ -33,7 +33,7 @@ class SpecialLog extends SpecialPage {
        /**
         * List log type for which the target is a user
         * Thus if the given target is in NS_MAIN we can alter it to be an NS_USER
-        * Title user instead. 
+        * Title user instead.
         */
        private $typeOnUser = array(
                'block',
@@ -47,7 +47,7 @@ class SpecialLog extends SpecialPage {
 
        public function execute( $par ) {
                global $wgLogRestrictions;
-               
+
                $this->setHeaders();
                $this->outputHeader();
 
@@ -65,7 +65,7 @@ class SpecialLog extends SpecialPage {
 
                // Set values
                $opts->fetchValuesFromRequest( $this->getRequest() );
-               if ( $par ) {
+               if ( $par !== null ) {
                        $this->parseParams( $opts, (string)$par );
                }
 
@@ -162,7 +162,7 @@ class SpecialLog extends SpecialPage {
 
        private function getRevisionButton( $formcontents ) {
                # If the user doesn't have the ability to delete log entries, don't bother showing him/her the button.
-               if ( !$this->getUser()->isAllowed( 'deletelogentry' ) ) {
+               if ( !$this->getUser()->isAllowedAll( 'deletedhistory', 'deletelogentry' ) ) {
                        return $formcontents;
                }
 
@@ -182,7 +182,6 @@ class SpecialLog extends SpecialPage {
                return $s;
        }
 
-
        /**
         * Set page title and show header for this log type
         * @param $type string
@@ -194,4 +193,7 @@ class SpecialLog extends SpecialPage {
                $this->getOutput()->addHTML( $page->getDescription()->parseAsBlock() );
        }
 
+       protected function getGroupName() {
+               return 'changes';
+       }
 }