Small bug fixes

This commit is contained in:
lucast committed 2026-02-03 15:54:49 +01:00
1 parent e952dd7b7a
commit 9474fa18f2
2 files changed
+2 -2

No files matched your search

+1
View File
@@ -16,6 +16,7 @@ const props = defineProps<CardProps>()
@use "@/styles/variables" as *;
.card {
background-color: $color-background;
border: 1px solid $color-border;
border-radius: $border-radius-standard;
padding: 1rem;
+1 -2
View File
@@ -48,14 +48,13 @@ export const cfetch = async (
for (const [key, val] of Object.entries(config.data)) {
if (Array.isArray(val)) {
val.forEach((v) => form.append(`${key}[]`, v))
val.forEach((v) => form.append(key, v)) // key as-is, no []
} else if (val !== undefined && val !== null) {
form.append(key, val as any)
}
}
config.data = form
if (!config.headers) config.headers = {}
delete config.headers["Content-Type"]
}