Commit 70630d74 by Daniel Lee

snapshots: removes errors for empty values in ViewStore

Occurs when opening a snapshot.
parent fdf7a4c4
......@@ -26,7 +26,9 @@ export const ViewStore = types
function updateQuery(query: any) {
self.query.clear();
for (let key of Object.keys(query)) {
self.query.set(key, query[key]);
if (query[key]) {
self.query.set(key, query[key]);
}
}
}
......@@ -34,7 +36,9 @@ export const ViewStore = types
function updateRouteParams(routeParams: any) {
self.routeParams.clear();
for (let key of Object.keys(routeParams)) {
self.routeParams.set(key, routeParams[key]);
if (routeParams[key]) {
self.routeParams.set(key, routeParams[key]);
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment