From 8a2c384d6ff9b804c1662430cf5bc9b0bd593e54 Mon Sep 17 00:00:00 2001 From: withoutaname Date: Mon, 21 Jul 2014 17:02:22 -0700 Subject: [PATCH] Remove functions deprecated since 1.19 from EditPage.php Specifically functions blockedPage(), noCreatePermission(), readOnlyPage() and userNotLoggedInPage(). Change-Id: I3f8b16037d15a8b743dff975a8d7fe2b531a40d9 --- RELEASE-NOTES-1.24 | 2 ++ includes/EditPage.php | 54 ------------------------------------------- 2 files changed, 2 insertions(+), 54 deletions(-) diff --git a/RELEASE-NOTES-1.24 b/RELEASE-NOTES-1.24 index 8e6e8f5512..7c86a915c3 100644 --- a/RELEASE-NOTES-1.24 +++ b/RELEASE-NOTES-1.24 @@ -284,6 +284,8 @@ changes to languages because of Bugzilla reports. and filelinks tables. Run update.php to apply this change to the schema. * Removed File::sha1Base36(). (deprecated since 1.19) * Removed File::getPropsFromPath(). (deprecated since 1.19) +* Removed functions blockedPage(), noCreatePermission(), readOnlyPage() and + userNotLoggedInPage() from EditPage.php. (deprecated since 1.19) ==== Renamed classes ==== * CLDRPluralRuleConverter_Expression to CLDRPluralRuleConverterExpression diff --git a/includes/EditPage.php b/includes/EditPage.php index 50225ccc65..7f9e7fc566 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -639,26 +639,6 @@ class EditPage { } } - /** - * Show a read-only error - * Parameters are the same as OutputPage:readOnlyPage() - * Redirect to the article page if redlink=1 - * @deprecated since 1.19; use displayPermissionsError() instead - */ - function readOnlyPage( $source = null, $protected = false, $reasons = array(), $action = null ) { - wfDeprecated( __METHOD__, '1.19' ); - - global $wgRequest, $wgOut; - if ( $wgRequest->getBool( 'redlink' ) ) { - // The edit page was reached via a red link. - // Redirect to the article page and let them click the edit tab if - // they really want a permission error. - $wgOut->redirect( $this->mTitle->getFullURL() ); - } else { - $wgOut->readOnlyPage( $source, $protected, $reasons, $action ); - } - } - /** * Should we show a preview when the edit form is first shown? * @@ -3902,40 +3882,6 @@ HTML echo $s; } - /** - * Call the stock "user is blocked" page - * - * @deprecated since 1.19; throw an exception directly instead - */ - function blockedPage() { - wfDeprecated( __METHOD__, '1.19' ); - global $wgUser; - - throw new UserBlockedError( $wgUser->getBlock() ); - } - - /** - * Produce the stock "please login to edit pages" page - * - * @deprecated since 1.19; throw an exception directly instead - */ - function userNotLoggedInPage() { - wfDeprecated( __METHOD__, '1.19' ); - throw new PermissionsError( 'edit' ); - } - - /** - * Show an error page saying to the user that he has insufficient permissions - * to create a new page - * - * @deprecated since 1.19; throw an exception directly instead - */ - function noCreatePermission() { - wfDeprecated( __METHOD__, '1.19' ); - $permission = $this->mTitle->isTalkPage() ? 'createtalk' : 'createpage'; - throw new PermissionsError( $permission ); - } - /** * Creates a basic error page which informs the user that * they have attempted to edit a nonexistent section. -- 2.20.1