Fix federation links

This commit is contained in:
Zef Hemel
2023-12-21 19:19:09 +01:00
parent 90659c9c7e
commit 5abdf1c80c
8 changed files with 7 additions and 17 deletions
+2 -7
View File
@@ -119,13 +119,8 @@ export async function readFile(
name: string,
): Promise<{ data: Uint8Array; meta: FileMeta } | undefined> {
const url = federatedPathToUrl(name);
console.log("Fetfching fedderated file", url);
const r = await nativeFetch(url, {
method: "GET",
headers: {
"X-Sync-Mode": "true",
},
});
console.log("Fetching fedderated file", url);
const r = await nativeFetch(url);
if (r.status === 503) {
throw new Error("Offline");
}