Fix flaky tests

It's normal that some of the "alias" queries return a 404 if a DID can't
be looked up, in this case the endpoint returns a 404 and we just log
it.
This commit is contained in:
Rūdolfs Ošiņš
2025-02-13 09:54:32 -06:00
parent 6cbd6336dc
commit c35b4a3dc5
+4
View File
@@ -13,6 +13,10 @@ export async function invoke<T = null>(
headers: { "Content-Type": "application/json" },
body: JSON.stringify(args),
}).then(async response => {
if (response.status === 404) {
console.log("Got a 404 response:", response);
return null;
}
const json = await response.json();
if (!response.ok) {
throw json;