Ori.livneh has uploaded a new change for review.
https://gerrit.wikimedia.org/r/291103
Change subject: Bail out in ApiStashEdit for bots for sanity
......................................................................
Bail out in ApiStashEdit for bots for sanity
checkCache() is disabled in this case anyway.
Change-Id: I1c18585eecc1a7c4c0e24546799c7ee448b3ea57
(cherry picked from commit d690083213140f19184d9c98de9c536d867abcc8)
---
M includes/api/ApiStashEdit.php
1 file changed, 4 insertions(+), 0 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/03/291103/1
diff --git a/includes/api/ApiStashEdit.php b/includes/api/ApiStashEdit.php
index 93003cc..2c18e6d 100644
--- a/includes/api/ApiStashEdit.php
+++ b/includes/api/ApiStashEdit.php
@@ -46,6 +46,10 @@
$user = $this->getUser();
$params = $this->extractRequestParams();
+ if ( $user->isBot() ) { // sanity
+ $this->dieUsage( 'This interface is not supported for
bots', 'botsnotsupported' );
+ }
+
$page = $this->getTitleOrPageId( $params );
$title = $page->getTitle();
--
To view, visit https://gerrit.wikimedia.org/r/291103
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I1c18585eecc1a7c4c0e24546799c7ee448b3ea57
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.28.0-wmf.2
Gerrit-Owner: Ori.livneh <[email protected]>
Gerrit-Reviewer: Aaron Schulz <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits