From 2f73113dbd94d5bd5bb5cba462c34d14b02cc24b Mon Sep 17 00:00:00 2001 From: xynydev Date: Sat, 10 Feb 2024 11:39:58 +0200 Subject: [PATCH] fix: check if res is ok, not 200 might fix always erroring even when functional --- src/components/ImageChooser/CreateRepo.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ImageChooser/CreateRepo.svelte b/src/components/ImageChooser/CreateRepo.svelte index 84a2a7f..9f5814a 100644 --- a/src/components/ImageChooser/CreateRepo.svelte +++ b/src/components/ImageChooser/CreateRepo.svelte @@ -53,7 +53,7 @@ } ); repo = await res.json(); - if (res.status != 200) { + if (!res.ok) { log += "Repo creation failed: \n"; log += JSON.stringify(repo); log += "\n";