From 1c496b8084dfaaf8998ea5a2a5d9aee922772194 Mon Sep 17 00:00:00 2001
From: Fuwn <contact@fuwn.me>
Date: Fri, 6 Oct 2023 21:34:25 -0700
Subject: fix(manga): highlist fast

---
 src/lib/List/Template/MangaListTemplate.svelte | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'src/lib/List/Template/MangaListTemplate.svelte')

diff --git a/src/lib/List/Template/MangaListTemplate.svelte b/src/lib/List/Template/MangaListTemplate.svelte
index f2f6cb15..018efd5c 100644
--- a/src/lib/List/Template/MangaListTemplate.svelte
+++ b/src/lib/List/Template/MangaListTemplate.svelte
@@ -107,10 +107,10 @@
 
 	const updateMedia = async (id: number, progress: number | undefined, media: Media[]) => {
 		pendingUpdate = id;
+		lastUpdatedMedia = id;
 
 		await chapterDatabase.chapters.delete(id);
 		await fetch(`/api/anilist-increment?id=${id}&progress=${(progress || 0) + 1}`).then(() => {
-			lastUpdatedMedia = id;
 			previousMangaList = media;
 			media.find((m) => m.id === id)!.mediaListEntry!.progress = (progress || 0) + 1;
 			mangaLists = mediaListCollection(
-- 
cgit v1.2.3

