diff --git a/frontend/src/app/pages/exercises/exercise/shared/exercise-map/utility/ol-map-manager.ts b/frontend/src/app/pages/exercises/exercise/shared/exercise-map/utility/ol-map-manager.ts index b125d3b95..624d24df9 100644 --- a/frontend/src/app/pages/exercises/exercise/shared/exercise-map/utility/ol-map-manager.ts +++ b/frontend/src/app/pages/exercises/exercise/shared/exercise-map/utility/ol-map-manager.ts @@ -423,15 +423,8 @@ export class OlMapManager { return false; } this.layerFeatureManagerDictionary - .get( - layer as VectorLayer< - VectorSource - > - )! - .onFeatureClicked( - event, - feature as Feature - ); + .get(layer as VectorLayer)! + .onFeatureClicked(event, feature as Feature); // we only want the top one -> a truthy return breaks this loop return true; }, @@ -473,15 +466,11 @@ export class OlMapManager { } // We stop propagating the event as soon as the onFeatureDropped function returns true return this.layerFeatureManagerDictionary - .get( - layer as VectorLayer> - )! + .get(layer as VectorLayer)! .onFeatureDrop( event, - event.features.getArray()[0] as Feature< - LineString | Point - >, - feature as Feature + event.features.getArray()[0]!, + feature as Feature ); }); });