Skip to content

Commit

Permalink
ensure this.sourceCaches exists before debounced updated
Browse files Browse the repository at this point in the history
  • Loading branch information
j8seangel committed Jun 2, 2022
1 parent da0762c commit 0c716c3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@globalfishingwatch/maplibre-gl",
"description": "BSD licensed community fork of mapbox-gl, a WebGL interactive maps library",
"version": "2.1.9-gfw.22",
"version": "2.1.9-gfw.23",
"main": "dist/maplibre-gl.js",
"style": "dist/maplibre-gl.css",
"license": "BSD-3-Clause",
Expand Down
2 changes: 1 addition & 1 deletion src/style/style.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1262,7 +1262,7 @@ class Style extends Evented {

_debouncedUpdateSource = debounce(
(id: string, transform: Transform) => {
this.sourceCaches[id].update(transform);
this.sourceCaches[id]?.update(transform);
},
60, {leading: true}
);
Expand Down

0 comments on commit 0c716c3

Please sign in to comment.