Merge pull request #11066 from annando/issue-11063

Issue 11063: Fix check for current user
This commit is contained in:
Hypolite Petovan
2021-12-03 23:47:19 -05:00
committed by GitHub

View File

@@ -88,7 +88,7 @@ class BaseApi extends BaseModule
case Router::PUT:
self::checkAllowedScope(self::SCOPE_WRITE);
if (!$this->app->isLoggedIn()) {
if (!self::getCurrentUserID()) {
throw new HTTPException\ForbiddenException($this->t('Permission denied.'));
}
break;