From: withoutaname Date: Tue, 22 Jul 2014 00:50:47 +0000 (-0700) Subject: Remove two unused constants from EditPage.php X-Git-Tag: 1.31.0-rc.0~14814^2 X-Git-Url: http://git.cyclocoop.org/data/%24self?a=commitdiff_plain;h=da5090774fd2374db92ea91308b8f5d2f4c4d975;p=lhc%2Fweb%2Fwiklou.git Remove two unused constants from EditPage.php Specifically constants AS_USER_CANNOT_EDIT and AS_OK Change-Id: I96b20962b7d4cab5c026a0f03abf9da066fbd9af --- diff --git a/includes/EditPage.php b/includes/EditPage.php index a8a68114c1..9d512abd30 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -66,11 +66,6 @@ class EditPage { */ const AS_CONTENT_TOO_BIG = 216; - /** - * Status: User cannot edit? (not used) - */ - const AS_USER_CANNOT_EDIT = 217; - /** * Status: this anonymous user is not allowed to edit this page */ @@ -129,11 +124,6 @@ class EditPage { */ const AS_MAX_ARTICLE_SIZE_EXCEEDED = 229; - /** - * not used - */ - const AS_OK = 230; - /** * Status: WikiPage::doEdit() was unsuccessful */ diff --git a/tests/phpunit/includes/EditPageTest.php b/tests/phpunit/includes/EditPageTest.php index 6b8bf2720f..28c35b3697 100644 --- a/tests/phpunit/includes/EditPageTest.php +++ b/tests/phpunit/includes/EditPageTest.php @@ -82,7 +82,7 @@ class EditPageTest extends MediaWikiLangTestCase { * * wpMinorEdit: mark as minor edit * * wpWatchthis: whether to watch the page * @param int|null $expectedCode The expected result code (EditPage::AS_XXX constants). - * Set to null to skip the check. Defaults to EditPage::AS_OK. + * Set to null to skip the check. * @param string|null $expectedText The text expected to be on the page after the edit. * Set to null to skip the check. * @param string|null $message An optional message to show along with any error message. @@ -90,7 +90,7 @@ class EditPageTest extends MediaWikiLangTestCase { * @return WikiPage The page that was just edited, useful for getting the edit's rev_id, etc. */ protected function assertEdit( $title, $baseText, $user = null, array $edit, - $expectedCode = EditPage::AS_OK, $expectedText = null, $message = null + $expectedCode = null, $expectedText = null, $message = null ) { if ( is_string( $title ) ) { $ns = $this->getDefaultWikitextNS();