Returning EditPage::AS_HOOK_ERROR rather than false in internalAttemptSave()
authorRoan Kattouw <catrope@users.mediawiki.org>
Fri, 25 Jan 2008 16:07:45 +0000 (16:07 +0000)
committerRoan Kattouw <catrope@users.mediawiki.org>
Fri, 25 Jan 2008 16:07:45 +0000 (16:07 +0000)
includes/EditPage.php

index 07813ed..97a2031 100644 (file)
@@ -811,7 +811,7 @@ class EditPage {
                        if ( !wfRunHooks( 'EditFilterMerged', array( $this, $this->textbox1, &$this->hookError ) ) ) {
                                # Error messages etc. could be handled within the hook...
                                wfProfileOut( $fname );
-                               return false;
+                               return self::AS_HOOK_ERROR;
                        }
 
                        $isComment = ( $this->section == 'new' );
@@ -894,7 +894,7 @@ class EditPage {
                if ( !wfRunHooks( 'EditFilterMerged', array( $this, $text, &$this->hookError ) ) ) {
                        # Error messages etc. could be handled within the hook...
                        wfProfileOut( $fname );
-                       return false;
+                       return self::AS_HOOK_ERROR;
                }
 
                # Handle the user preference to force summaries here, but not for null edits