Skip to content

Commit

Permalink
Fix crash updating settings (#2222)
Browse files Browse the repository at this point in the history
  • Loading branch information
Pessimistress authored Jul 6, 2023
1 parent 2c8951c commit 5d68c5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mapbox/mapbox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -525,7 +525,7 @@ export default class Mapbox<MapT extends MapInstance = MapInstance> {
if (propName in nextProps && !deepEqual(nextProps[propName], currProps[propName])) {
changed = true;
const setter = map[`set${propName[0].toUpperCase()}${propName.slice(1)}`];
setter?.(nextProps[propName]);
setter?.call(map, nextProps[propName]);
}
}
return changed;
Expand Down

0 comments on commit 5d68c5b

Please sign in to comment.