Add links-mode embed thumbnails, item metadata, and media filters

This commit is contained in:
Fisto
2026-09-16 11:44:09 +02:00
parent 1fe204b91e
commit 973b9cff92
23 changed files with 863 additions and 82 deletions
+5 -1
View File
@@ -30,7 +30,11 @@ async function request(path, options) {
} catch {
throw new Error(`request failed (${response.status})`);
}
if (!body.ok) throw new Error(body.error ?? `request failed (${response.status})`);
if (!body.ok) {
const error = new Error(body.error ?? `request failed (${response.status})`);
if (body.code) error.code = body.code;
throw error;
}
return body.result;
}