fix: file-show: spinner staying even after content loading fails
Massimo Melina committed
Jan 2, 2024 at 17:30 UTC
4fcc9c0906d5019b399646924e7c69b6f24a2538
1 file changed
+3
-1
frontend/src/show.ts
+3
-1
@@ -100,7 +100,9 @@ export function fileShow(entry: DirEntry) {
100
setLoading(false)
101
},
102
onError: () => {
103
- go()
103
+ if (cur !== lastGood.current)
104
+ return go()
105
+ setLoading(false)
106
setFailed(cur.n)
107
}
108
})