mirror of
https://gitlab.com/soapbox-pub/shakespeare.git
synced 2026-12-05 16:23:36 +00:00
Fix encoding of index.html
This commit is contained in:
1 file changed
+3
-2
@@ -187,10 +187,11 @@ class FetchClient {
|
||||
throw new Error(`Unexpected Content-Type: ${response.headers["Content-Type"]}`);
|
||||
}
|
||||
|
||||
const decoded = atob(response.body);
|
||||
const bytes = new Uint8Array(atob(response.body).split('').map(c => c.charCodeAt(0)));
|
||||
const text = new TextDecoder().decode(bytes);
|
||||
|
||||
// Replace current document with the site index content
|
||||
this.replaceDocument(decoded);
|
||||
this.replaceDocument(text);
|
||||
} catch (error) {
|
||||
this.showError("Failed to load site index", error);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user