diff --git a/app/controllers/shared/api.php b/app/controllers/shared/api.php index 5b3963a89e..1fee484c4c 100644 --- a/app/controllers/shared/api.php +++ b/app/controllers/shared/api.php @@ -557,8 +557,8 @@ App::init() if ($useCache) { $route = $utopia->match($request); $isImageTransformation = $route->getPath() === '/v1/storage/buckets/:bucketId/files/:fileId/preview'; - // Plan-level disable (legacy) - -1 means disabled - $isDisabled = isset($plan['imageTransformations']) && $plan['imageTransformations'] === -1; + $isDisabled = isset($plan['imageTransformations']) && $plan['imageTransformations'] === -1 && !Auth::isPrivilegedUser(Authorization::getRoles()); + $key = $request->cacheIdentifier(); $cacheLog = Authorization::skip(fn () => $dbForProject->getDocument('cache', $key));