aboutsummaryrefslogtreecommitdiff
path: root/src/routes/settings
diff options
context:
space:
mode:
Diffstat (limited to 'src/routes/settings')
-rw-r--r--src/routes/settings/+page.svelte10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/routes/settings/+page.svelte b/src/routes/settings/+page.svelte
index 2fe6b466..6cc336e6 100644
--- a/src/routes/settings/+page.svelte
+++ b/src/routes/settings/+page.svelte
@@ -7,6 +7,7 @@
import settings from '../../stores/settings';
import SettingToggle from '$lib/Settings/SettingToggle.svelte';
import SettingHint from '$lib/Settings/SettingHint.svelte';
+ import { pruneAllManga } from '$lib/Media/manga';
export let data;
@@ -18,13 +19,6 @@
anime.set('');
await chapterDatabase.chapters.bulkDelete(ids);
};
- const pruneAll = async () => {
- const all = await chapterDatabase.chapters.toArray();
- const ids = all.map((m) => m.id);
-
- manga.set('');
- await chapterDatabase.chapters.bulkDelete(ids);
- };
</script>
{#if data.user === undefined}
@@ -129,7 +123,7 @@
<p />
- <a href={'#'} on:click={pruneAll}>Re-cache <b>ALL</b> manga</a>
+ <a href={'#'} on:click={pruneAllManga}>Re-cache <b>ALL</b> manga</a>
<SettingHint lineBreak>Force a re-cache of all cached manga chapter counts</SettingHint>
<p />