mapbox / mapbox-gl-native

Interactive, thoroughly customizable maps in native Android, iOS, macOS, Node.js, and Qt applications, powered by vector tiles and OpenGL
https://mapbox.com/mobile
Other
4.35k stars 1.33k forks source link

reason: 'Source marker-source already exists' #16614

Open cnfuzedRk62 opened 3 years ago

cnfuzedRk62 commented 3 years ago
. I am using MapBox ios Sdk version, Mapbox-iOS-SDK', '~> 6.3.0' I am facing issue while removing the source layer or the source marker which is already present on the map. First time it is working fine, while second time when i am going to set the new marker on different lat long then i am going to remove already present layer and source marker from the map. Till now there is no crash at all, but after this when i am trying to add again the same layer then my app got crash with this error:- reason: 'Source marker-source already exists'. SO basically after adding source remove statement & layer remove statement , in the console it is still showing that you have the source and the layer with the same name, but in reality i already removed that one. But it is not working. I am attaching my screenshot of the code as well. ### Configuration **Mapbox SDK versions:** Mapbox-iOS-SDK', '~> 6.3.0' **iOS/macOS versions:** iOS 14.5 **Device/simulator models:** iPhone All models **Xcode version:** Xcode 12.2 Screenshot 2021-06-20 at 1 41 00 PM