jenkins-bot has submitted this change and it was merged.
Change subject: ApiQueryStashImageInfo: Don't throw exceptions when the user is
not logged in
......................................................................
ApiQueryStashImageInfo: Don't throw exceptions when the user is not logged in
Bug: T130253
Change-Id: If70b919c65a21b57b3022d495756bf250b0ba786
---
M includes/api/ApiQueryStashImageInfo.php
1 file changed, 4 insertions(+), 0 deletions(-)
Approvals:
Anomie: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/api/ApiQueryStashImageInfo.php
b/includes/api/ApiQueryStashImageInfo.php
index 6d1540b..b039a1e 100644
--- a/includes/api/ApiQueryStashImageInfo.php
+++ b/includes/api/ApiQueryStashImageInfo.php
@@ -32,6 +32,10 @@
}
public function execute() {
+ if ( !$this->getUser()->isLoggedIn() ) {
+ $this->dieUsage( 'You must be logged-in to have an
upload stash', 'notloggedin' );
+ }
+
$params = $this->extractRequestParams();
$modulePrefix = $this->getModulePrefix();
--
To view, visit https://gerrit.wikimedia.org/r/278210
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: If70b919c65a21b57b3022d495756bf250b0ba786
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński <[email protected]>
Gerrit-Reviewer: Anomie <[email protected]>
Gerrit-Reviewer: Gergő Tisza <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits