Skip to content

A continuation of HomeBox the inventory and organization system built for the Home User

Fix the parent location being undefined when set while the locationStore is empty. (#571)

EdWorth1203baf1a5c92ba
diff --git a/frontend/pages/location/[id].vue b/frontend/pages/location/[id].vue
index 8ac048c6..435b45a5 100644
--- a/frontend/pages/location/[id].vue
+++ b/frontend/pages/location/[id].vue
@@ -27,6 +27,10 @@
parent.value = locations.value.find(l => l.id === data.parent.id);
}
+ if (parent.value === undefined) {
+ parent.value = data.parent;
+ }
+
return data;
});