Skip to content
Snippets Groups Projects
Commit 852f9491 authored by Marin Karamihalev's avatar Marin Karamihalev
Browse files

removed undefined filter in get return

parent e7a8b6ee
No related branches found
No related tags found
No related merge requests found
Pipeline #40220 passed
......@@ -141,7 +141,7 @@ export const fullyUnwrapObject = (obj: any, shouldBeArray: boolean) => {
return fullyUnwrapObject(Object.values(obj)[0], shouldBeArray);
const isArray = Array.isArray(obj);
if (shouldBeArray)
if (isArray) return obj.filter((it) => it !== null && it !== null);
if (isArray) return obj;
else return [obj];
else if (isArray)
return fullyUnwrapObject(
......
......@@ -220,7 +220,7 @@ describe("Test general API", () => {
.get("Device.DeviceInfo.SerialNumber");
});
it.only("downloaddiagnostic() executes without error", async () => {
it("downloaddiagnostic() executes without error", async () => {
const [op, clearOp] = await device.operate(
"Device.IP.Diagnostics.DownloadDiagnostics()"
);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment