Return empty on no collection, fallback to route validation

This commit is contained in:
Jake Barnby 2025-10-28 16:50:38 +13:00
parent dde6968e50
commit 8a5a6037b1

View file

@ -146,8 +146,8 @@ class V20 extends Filter
if ($database->isEmpty()) {
return [];
}
} catch (NotFound) {
throw new Exception(Exception::DATABASE_NOT_FOUND);
} catch (\Throwable) {
return [];
}
try {
@ -158,8 +158,8 @@ class V20 extends Filter
if ($collection->isEmpty()) {
return [];
}
} catch (NotFound) {
throw new Exception(Exception::COLLECTION_NOT_FOUND);
} catch (\Throwable) {
return [];
}
$attributes = $collection->getAttribute('attributes', []);