From d1e90b650d2986ded98150f8cfdaab6965f39107 Mon Sep 17 00:00:00 2001 From: Reedy Date: Tue, 3 Apr 2012 19:07:19 +0100 Subject: [PATCH] Bug 35671 - PHP Notice: Undefined index: gettoken in includes/api/ApiMain.php on line 598 Change-Id: I220dfcd964ceb4254b310140b916a7c63a3044ef --- includes/api/ApiMain.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/api/ApiMain.php b/includes/api/ApiMain.php index 8f5cfcaf51..8fd8883109 100644 --- a/includes/api/ApiMain.php +++ b/includes/api/ApiMain.php @@ -595,7 +595,7 @@ class ApiMain extends ApiBase { // Die if token required, but not provided (unless there is a gettoken parameter) $salt = $module->getTokenSalt(); - if ( $salt !== false && !$moduleParams['gettoken'] ) { + if ( $salt !== false && isset( $moduleParams['gettoken'] ) && !$moduleParams['gettoken'] ) { if ( !isset( $moduleParams['token'] ) ) { $this->dieUsageMsg( array( 'missingparam', 'token' ) ); } else { -- 2.20.1