]> git.mxchange.org Git - friendica.git/commitdiff
Issue 11063: Fix check for current user
authorMichael <heluecht@pirati.ca>
Sat, 4 Dec 2021 04:30:46 +0000 (04:30 +0000)
committerMichael <heluecht@pirati.ca>
Sat, 4 Dec 2021 04:30:46 +0000 (04:30 +0000)
src/Module/BaseApi.php

index db5f191cf1d0bd6b63c421f82ab4598544afc667..233edeec8a4b6fd2eb521a3cf8324d4f2eec88a7 100644 (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;