mapbox-gl-directions icon indicating copy to clipboard operation
mapbox-gl-directions copied to clipboard

Error when using custom styles and removeControl method

Open bryantAXS opened this issue 7 years ago • 1 comments

I'm getting the error: Uncaught TypeError: Cannot read property 'recalculate' of undefined after I use the map.removeControl method on the directions control. Also, it's only happening when using custom styles.

Here's a JSFiddle showing the issue: https://jsfiddle.net/bryantaxs/uomq0zvz/

Any thoughts on this one?

bryantAXS avatar Feb 06 '18 15:02 bryantAXS

Hi @bryantAXS – thanks for the report.This should be fixed by #168

mollymerp avatar Feb 15 '18 17:02 mollymerp