From a6d7ddecdb8c9841ec8051a20c497a21984c51b4 Mon Sep 17 00:00:00 2001 From: Varun Patil Date: Wed, 16 Aug 2023 08:16:06 -0700 Subject: [PATCH] clusters: add error message to preview Signed-off-by: Varun Patil --- lib/Controller/ClustersController.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/Controller/ClustersController.php b/lib/Controller/ClustersController.php index 3f128665..f4bf246b 100644 --- a/lib/Controller/ClustersController.php +++ b/lib/Controller/ClustersController.php @@ -68,7 +68,9 @@ class ClustersController extends GenericApiController // If no photos found then return 404 if (0 === \count($photos)) { - return new JSONResponse([], Http::STATUS_NOT_FOUND); + return new JSONResponse([ + 'message' => 'No photos found in this cluster', + ], Http::STATUS_NOT_FOUND); } // Put the photos in the correct order