Fix exception when using 'true' as filter

This commit is contained in:
Zaid Abdulla committed 2019-06-05 00:17:36 -07:00
1 parent 63876025d2
commit 7269c726fc
8 files changed
+16 -16

No files matched your search

+2 -2
View File
@@ -47,8 +47,8 @@ export function init(args): Promise<{}> {
if (!window.authorizer.hasAccess("devices", 2))
return void reject(new Error("You are not authorized to view this page"));
const filter = args.filter;
const sort = args.sort;
const filter = args.hasOwnProperty("filter") ? "" + args["filter"] : "";
const sort = args.hasOwnProperty("sort") ? "" + args["sort"] : "";
const indexParameters = Object.values(config.ui.index);
resolve({ filter, indexParameters, sort });
});