Victorbarbu has uploaded a new change for review.
https://gerrit.wikimedia.org/r/265230
Change subject: [WIP]Add logic for "tags" in ApiBase
......................................................................
[WIP]Add logic for "tags" in ApiBase
Change-Id: I275c516b4744e243333ec0818d2be1e5508e54a3
---
M includes/api/ApiBase.php
1 file changed, 9 insertions(+), 0 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/30/265230/1
diff --git a/includes/api/ApiBase.php b/includes/api/ApiBase.php
index 5f67a22..ed634e4 100644
--- a/includes/api/ApiBase.php
+++ b/includes/api/ApiBase.php
@@ -1052,6 +1052,15 @@
break;
case 'upload': // nothing to do
break;
+ case 'tag':
+ if ( is_array( $value ) &&
count( $value ) ) {
+ $user =
$this->getUser();
+ $tagStatus =
ChangeTags::canAddTagsAccompanyingChange( $value, $user );
+ if (
!$tagStatus->isOK() ) {
+
$this->dieStatus( $tagStatus );
+ }
+ }
+ break;
default:
ApiBase::dieDebug( __METHOD__,
"Param $encParamName's type is unknown - $type" );
}
--
To view, visit https://gerrit.wikimedia.org/r/265230
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I275c516b4744e243333ec0818d2be1e5508e54a3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Victorbarbu <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits