From 852a55e6fa090289e04b5a0ea49fecdafbbeca50 Mon Sep 17 00:00:00 2001 From: ale Date: Mon, 23 Sep 2024 02:20:45 +0200 Subject: [PATCH] download index --- public/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/main.js b/public/main.js index f661134..c8512a9 100644 --- a/public/main.js +++ b/public/main.js @@ -112,11 +112,11 @@ document.addEventListener('DOMContentLoaded', function () { document.getElementById('download_index').addEventListener('click', function (event) { loading() ac = new AbortController() - fetch('/api/donwload_index', { signal: ac.signal }).then(async function (result) { + fetch('/api/download_index', { signal: ac.signal }).then(async function (result) { var res = await result.blob(), a = document.createElement('a') a.download = 'fediblock-index.json.gz' - a.href = URL.createObjectURL(res) + a.href = URL.createObjectURL([res]) a.type = 'application/x-gzip' a.target = '_blank' a.dispatchEvent(new MouseEvent('click'))