From e20ee1e488b26c29e1c468be40ecc7b79f73a6a7 Mon Sep 17 00:00:00 2001 From: Ruben Thoms Date: Thu, 27 Jun 2024 16:44:26 +0200 Subject: [PATCH] Fixed issue --- .../src/modules/Intersection/settings/atoms/baseAtoms.ts | 2 -- .../src/modules/Intersection/settings/atoms/derivedAtoms.ts | 5 +++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/frontend/src/modules/Intersection/settings/atoms/baseAtoms.ts b/frontend/src/modules/Intersection/settings/atoms/baseAtoms.ts index 71ae6f0b6..637339d10 100644 --- a/frontend/src/modules/Intersection/settings/atoms/baseAtoms.ts +++ b/frontend/src/modules/Intersection/settings/atoms/baseAtoms.ts @@ -12,5 +12,3 @@ export const userSelectedFieldIdentifierAtom = atom(null); export const userSelectedEnsembleIdentAtom = atom(null); export const userSelectedWellboreUuidAtom = atom(null); export const userSelectedCustomIntersectionPolylineIdAtom = atom(null); - -export const layerManagerBaseAtom = atom(new LayerManager()); diff --git a/frontend/src/modules/Intersection/settings/atoms/derivedAtoms.ts b/frontend/src/modules/Intersection/settings/atoms/derivedAtoms.ts index 511d89b7f..0d02a7620 100644 --- a/frontend/src/modules/Intersection/settings/atoms/derivedAtoms.ts +++ b/frontend/src/modules/Intersection/settings/atoms/derivedAtoms.ts @@ -2,12 +2,12 @@ import { EnsembleIdent } from "@framework/EnsembleIdent"; import { EnsembleSet } from "@framework/EnsembleSet"; import { EnsembleRealizationFilterFunctionAtom, EnsembleSetAtom } from "@framework/GlobalAtoms"; import { IntersectionPolylinesAtom } from "@framework/userCreatedItems/IntersectionPolylines"; +import { LayerManager } from "@modules/Intersection/utils/layers/LayerManager"; import { atom } from "jotai"; import { queryClientAtom } from "jotai-tanstack-query"; import { - layerManagerBaseAtom, userSelectedCustomIntersectionPolylineIdAtom, userSelectedEnsembleIdentAtom, userSelectedFieldIdentifierAtom, @@ -121,8 +121,9 @@ export const selectedWellboreAtom = atom((get) => { }); export const layerManagerAtom = atom((get) => { + console.debug("Creating LayerManager"); + const layerManager = new LayerManager(); const queryClient = get(queryClientAtom); - const layerManager = get(layerManagerBaseAtom); layerManager.setQueryClient(queryClient); return layerManager;