Ljonka has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/390241 )
Change subject: BlueSpiceFoundation: BSApiTaskBase - add returning error code
to prevet crash in mw js api error handling
......................................................................
BlueSpiceFoundation: BSApiTaskBase - add returning error code to prevet crash
in mw js api error handling
Change-Id: Iae9a4d06156716517583b587c03fa6b61204c160
---
M includes/api/BSApiTasksBase.php
1 file changed, 3 insertions(+), 2 deletions(-)
git pull
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceFoundation
refs/changes/41/390241/1
diff --git a/includes/api/BSApiTasksBase.php b/includes/api/BSApiTasksBase.php
index c331748..68e7552 100644
--- a/includes/api/BSApiTasksBase.php
+++ b/includes/api/BSApiTasksBase.php
@@ -160,6 +160,7 @@
$mCode = 'dberror';
//TODO: error code for subtypes like DBQueryError or DBReadOnlyError?
}
$oResult->errors[$mCode] =
$e->getMessage();
+ $oResult->errors[0]['code'] =
'unknown error';
}
}
@@ -562,7 +563,7 @@
}
protected function returnTaskDataSchema( $sTaskName ) {
- $this->getResult()->addValue(
+ $this->getResult()->addValue(
null,
'schema',
$this->oTasksSpec->getSchema( $sTaskName )
@@ -570,7 +571,7 @@
}
protected function returnTaskDataExamples( $sTaskName ) {
- $this->getResult()->addValue(
+ $this->getResult()->addValue(
null,
'examples',
$this->oTasksSpec->getExamples( $sTaskName )
--
To view, visit https://gerrit.wikimedia.org/r/390241
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iae9a4d06156716517583b587c03fa6b61204c160
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BlueSpiceFoundation
Gerrit-Branch: master
Gerrit-Owner: Ljonka <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits