Skip to content

fix(submap): invalid pin position after submap is closed (MIN-290)

The problem is that the logic of the mapDataMiddlewareListener, which is responsible for the data regarding the current map, validates the correctness of actions and data by verifying the modelId property in the action payload (the modelId in the payload should not be the same as the modelId of the currently active map). We were sending the action closeMapAndSetMainMapActive with the modelId of an already opened map that we wanted to close, instead of the modelId of the map to be opened, as in the rest of the actions handled by mapDataMiddlewareListener. This caused it to not pass through the if check, resulting in the lack of updating the currently opened map and its data. After closing the submap in the store, we still had data from the closed submap instead of the main map.

invalid-pin-position

Merge request reports

Loading