jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/334400 )
Change subject: EditPage: switch from NS_CATEGORY check to instanceof
CategoryPage
......................................................................
EditPage: switch from NS_CATEGORY check to instanceof CategoryPage
Change-Id: I0ee3672a3d698eda25191bccbbc10c9e2f9f7546
---
M includes/EditPage.php
1 file changed, 2 insertions(+), 2 deletions(-)
Approvals:
Florianschmidtwelzow: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/EditPage.php b/includes/EditPage.php
index e070ca3..f171443 100644
--- a/includes/EditPage.php
+++ b/includes/EditPage.php
@@ -3282,14 +3282,14 @@
*/
protected function showPreview( $text ) {
global $wgOut;
- if ( $this->mTitle->getNamespace() == NS_CATEGORY ) {
+ if ( $this->mArticle instanceof CategoryPage ) {
$this->mArticle->openShowCategory();
}
# This hook seems slightly odd here, but makes things more
# consistent for extensions.
Hooks::run( 'OutputPageBeforeHTML', [ &$wgOut, &$text ] );
$wgOut->addHTML( $text );
- if ( $this->mTitle->getNamespace() == NS_CATEGORY ) {
+ if ( $this->mArticle instanceof CategoryPage ) {
$this->mArticle->closeShowCategory();
}
}
--
To view, visit https://gerrit.wikimedia.org/r/334400
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I0ee3672a3d698eda25191bccbbc10c9e2f9f7546
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Addshore <[email protected]>
Gerrit-Reviewer: Aaron Schulz <[email protected]>
Gerrit-Reviewer: Florianschmidtwelzow <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits