Skip to content

A continuation of HomeBox the inventory and organization system built for the Home User

fix: attachments not loading error

tonyaellie22f35a272c39
diff --git a/frontend/lib/api/base/base-api.ts b/frontend/lib/api/base/base-api.ts
index 41c144e7..38c03767 100644
--- a/frontend/lib/api/base/base-api.ts
+++ b/frontend/lib/api/base/base-api.ts
@@ -78,7 +78,12 @@ export class BaseAPI {
authURL(url: string): string {
if (this.attachmentToken) {
const { selectedId } = useCollections();
- return route(url, { access_token: this.attachmentToken, tenant: selectedId.value });
+ return route(
+ url,
+ selectedId.value
+ ? { access_token: this.attachmentToken, tenant: selectedId.value }
+ : { access_token: this.attachmentToken }
+ );
}
return url;
}