From 0648ae22b5a71a44700ef5f6d9ee736bb3b4fa73 Mon Sep 17 00:00:00 2001 From: Yuto Takano Date: Mon, 2 Dec 2024 12:54:04 +0100 Subject: [PATCH] Allow setting 0 as item cost in admin page --- src/routes/admin.items.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/admin.items.tsx b/src/routes/admin.items.tsx index 18aea20..4b4644e 100644 --- a/src/routes/admin.items.tsx +++ b/src/routes/admin.items.tsx @@ -140,7 +140,7 @@ export async function action({ request }: ActionFunctionArgs) { } if (method == "new") { - if (!name || !image_url || !description || !star_cost || !stock_count || !max_per_user) { + if (!name || !image_url || !description) { session.flash("error", "All fields are required."); return redirect("/admin/items", { headers: {