Pwirth has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/206378

Change subject: fix for required options on api call
......................................................................

fix for required options on api call

(need cherry pick to REL1_23)

Change-Id: Iba469f364543c4f0fde8b786b5840474009d7ca9
(cherry picked from commit 4e717166da56c72cb9e515da8e242f10cc81be0f)
---
M includes/CoreHooks.php
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceFoundation 
refs/changes/78/206378/1

diff --git a/includes/CoreHooks.php b/includes/CoreHooks.php
index 21b78cd..43b96ba 100644
--- a/includes/CoreHooks.php
+++ b/includes/CoreHooks.php
@@ -317,7 +317,8 @@
                if (!$module instanceof ApiParse) {
                        return true;
                }
-               if 
(Title::newFromText($module->getRequest()->getVal('page'))->userCan('read') == 
false){
+               $oTitle = Title::newFromText( $module->getRequest()->getVal( 
'page' ) );
+               if ( !is_null( $oTitle ) && $oTitle->userCan( 'read' ) == false 
) {
                        $message = wfMessage('loginreqpagetext', 
wfMessage('loginreqlink')->plain())->plain();
                        return false;
                }

-- 
To view, visit https://gerrit.wikimedia.org/r/206378
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iba469f364543c4f0fde8b786b5840474009d7ca9
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BlueSpiceFoundation
Gerrit-Branch: REL1_23
Gerrit-Owner: Pwirth <wi...@hallowelt.biz>
Gerrit-Reviewer: Tweichart <weich...@hallowelt.biz>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to