Tpt has uploaded a new change for review. https://gerrit.wikimedia.org/r/295899
Change subject: Debug the onEditFilterMergedContent hook ...................................................................... Debug the onEditFilterMergedContent hook Change-Id: I108c0d1e9d225815e523c04ee8e5a2a862793013 --- M ProofreadPage.body.php 1 file changed, 5 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ProofreadPage refs/changes/99/295899/1 diff --git a/ProofreadPage.body.php b/ProofreadPage.body.php index ed727a3..6c7524d 100644 --- a/ProofreadPage.body.php +++ b/ProofreadPage.body.php @@ -20,6 +20,7 @@ */ use ProofreadPage\Context; +use ProofreadPage\Page\PageContent; use ProofreadPage\Page\PageContentBuilder; use ProofreadPage\FileNotFoundException; use ProofreadPage\Pagination\PageNotInPaginationException; @@ -590,16 +591,16 @@ * @param $context Object implementing the IContextSource interface. * @param $content Content of the edit box, as a Content object. * @param $status Status object to represent errors, etc. - * @param $summary Edit summary for page + * @param $summary Edit summary for page * @param $user The User object representing the user whois performing the edit. * @param $minoredit Whether the edit was marked as minor by the user. * @return bool */ public static function onEditFilterMergedContent( IContextSource $context, Content $content, - Status $status, string $summary, User $user, boolean $minoredit ) { + Status $status, $summary, User $user, $minoredit ) { // If the content's model isn't ours, ignore this; there's nothing for us to do here. - if ( ! ( $content->contentModel instanceof ProofreadPageContent ) ) { + if ( ! ( $content instanceof PageContent ) ) { return true; } @@ -620,7 +621,7 @@ // Fail if the user changed the level and the change isn't allowed if ( - !$newLevel->equals( $oldLevel ) && !$oldLevel->isChangeAllowed( $newLevel ) + !$oldLevel->isChangeAllowed( $newLevel ) ) { $ourStatus = Status::newFatal( 'proofreadpage_notallowedtext' ); } -- To view, visit https://gerrit.wikimedia.org/r/295899 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I108c0d1e9d225815e523c04ee8e5a2a862793013 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/ProofreadPage Gerrit-Branch: master Gerrit-Owner: Tpt <thoma...@hotmail.fr> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits