fixed infinite loading on new application

This commit is contained in:
2025-10-20 10:07:59 -04:00
parent 6d4a29e0c3
commit a67a66db1b

View File

@@ -21,16 +21,16 @@ onMounted(async () => {
try {
//get app ID from URL param
const router = useRoute();
const appIDRaw = router.params.id.toString();
const raw = await loadApplication(appIDRaw);
console.log(raw);
if (raw === null) {
const appIDRaw = router.params.id;
if (appIDRaw === undefined) {
//new app
appData.value = null
readOnly.value = false;
newApp.value = true;
} else {
//load app
const raw = await loadApplication(appIDRaw.toString());
const data = raw.application;
appID.value = data.id;