Merge pull request #12395 from HankG/fix-photo-get-without-scale-arg

Fix Friendica Photo GET API endpoint to work without explicit scale term
This commit is contained in:
Hypolite Petovan 2022-12-12 13:00:19 -05:00 committed by GitHub
commit 27c738f90f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,7 +54,7 @@ class Photo extends BaseApi
throw new HTTPException\BadRequestException('No photo id.');
}
$scale = (!empty($request['scale']) ? intval($request['scale']) : false);
$scale = (!empty($request['scale']) ? intval($request['scale']) : null);
$photo_id = $request['photo_id'];
// prepare json/xml output with data from database for the requested photo