Code Cleanup™

This commit is contained in:
2024-02-11 11:16:23 +01:00
parent 4b27eb76fe
commit 9fd8ddb9bd
62 changed files with 663 additions and 519 deletions

View File

@@ -22,7 +22,7 @@
import {Button, Input, Label, Modal, Range, Select, Toast, Toggle} from "flowbite-svelte";
import {schemTypes} from "@stores/stores.ts";
import dayjs from "dayjs";
import utc from "dayjs/plugin/utc"
import utc from "dayjs/plugin/utc";
import {eventRepo, type UpdateEvent} from "@repo/event.ts";
import ErrorModal from "../../components/ErrorModal.svelte";
import {replace} from "svelte-spa-router";
@@ -55,7 +55,7 @@
return {
value: type.db,
name: type.name
}
};
})];
$: changed = name !== event.name ||
@@ -70,7 +70,7 @@
async function del() {
try {
await $eventRepo.deleteEvent(event.id.toString());
await replace("/")
await replace("/");
} catch (e) {
error = e;
errorOpen = true;
@@ -86,7 +86,7 @@
maxTeamMembers: member,
name: name,
publicSchemsOnly: publicOnly,
schemType: schemType ?? 'null',
schemType: schemType ?? "null",
spectateSystem: spectateSystem,
start: startDate
};