mobility-toolbox-js 3.0.1-beta.2 → 3.0.1-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/mbt.js CHANGED
@@ -45629,15 +45629,16 @@ uniform ${i3} ${a3} u_${s3};
45629
45629
  this.ignoreNextRender = false;
45630
45630
  }
45631
45631
  renderFrame(frameState) {
45632
+ const layer = this.getLayer();
45633
+ const { mapLibreMap } = layer;
45634
+ const map = layer.getMapInternal();
45632
45635
  this.getLayer()?.mapLibreMap?.off("idle", this.setIsReady);
45633
- const mapLibreMap = this.getLayer()?.mapLibreMap;
45634
- mapLibreMap?.off("idle", this.setIsReady);
45636
+ if (!layer || !map || !mapLibreMap) {
45637
+ return null;
45638
+ }
45635
45639
  if (this.ignoreNextRender) {
45636
45640
  this.ignoreNextRender = false;
45637
- const container2 = mapLibreMap?.getContainer();
45638
- if (container2) {
45639
- return container2;
45640
- }
45641
+ return mapLibreMap?.getContainer();
45641
45642
  }
45642
45643
  this.ready = false;
45643
45644
  const container = super.renderFrame(frameState);