From 30c450552c660bc74453d246673af4cbb58e0fcd Mon Sep 17 00:00:00 2001 From: umherirrender Date: Tue, 20 May 2014 21:21:13 +0200 Subject: [PATCH] Add missing possible errors to ApiRollback.php requireOnlyOneParameter was added in I346c6ae4fc0b48c5a794c3d621018baf9bde6b9e, without update of the possible error list from that function call Change-Id: Iea51b9fc54d6854541509d44fad48a99db278fff --- includes/api/ApiRollback.php | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/includes/api/ApiRollback.php b/includes/api/ApiRollback.php index fbe87d2c1c..d0ce6d7dbf 100644 --- a/includes/api/ApiRollback.php +++ b/includes/api/ApiRollback.php @@ -149,12 +149,16 @@ class ApiRollback extends ApiBase { } public function getPossibleErrors() { - return array_merge( parent::getPossibleErrors(), array( - array( 'invalidtitle', 'title' ), - array( 'notanarticle' ), - array( 'nosuchpageid', 'pageid' ), - array( 'invaliduser', 'user' ), - ) ); + return array_merge( + parent::getPossibleErrors(), + $this->getRequireOnlyOneParameterErrorMessages( array( 'title', 'pageid' ) ), + array( + array( 'invalidtitle', 'title' ), + array( 'notanarticle' ), + array( 'nosuchpageid', 'pageid' ), + array( 'invaliduser', 'user' ), + ) + ); } public function needsToken() { -- 2.20.1