From 5e6f7825ad7f729271ae5029fdaeb4aa32dadde4 Mon Sep 17 00:00:00 2001 From: Garrett Stevens Date: Mon, 18 Nov 2024 17:23:16 -0700 Subject: [PATCH] Revert usage of structuredClone --- .../src/OntologyManager/OntologyStore/index.test.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/jbrowse-plugin-apollo/src/OntologyManager/OntologyStore/index.test.ts b/packages/jbrowse-plugin-apollo/src/OntologyManager/OntologyStore/index.test.ts index 57f7f2b81..d7a5e8a7c 100644 --- a/packages/jbrowse-plugin-apollo/src/OntologyManager/OntologyStore/index.test.ts +++ b/packages/jbrowse-plugin-apollo/src/OntologyManager/OntologyStore/index.test.ts @@ -24,7 +24,8 @@ jest.mock('jsonpath', () => { ...original, // eslint-disable-next-line @typescript-eslint/no-explicit-any query: jest.fn((obj: any, pathExpression: string, count?: number) => { - const newObj = obj instanceof Object ? obj : structuredClone(obj) + const newObj = + obj instanceof Object ? obj : JSON.parse(JSON.stringify(obj)) return original.query(newObj, pathExpression, count) }), }