diff --git a/src/DeckGLMapViewController.ts b/src/DeckGLMapViewController.ts index ebedb0c..d14e275 100644 --- a/src/DeckGLMapViewController.ts +++ b/src/DeckGLMapViewController.ts @@ -315,13 +315,13 @@ export class DeckGLMapViewController setMarkerAnimationOverlayHost(host: MarkerAnimationOverlayHost | null): void { this.markerController.setMarkerAnimationOverlayHost(host); } async clearOverlays(): Promise { - await Promise.all([ - this.markerController.clear(), - this.circleController.clear(), - this.polylineController.clear(), - this.polygonController.clear(), - this.groundImageController.clear(), - this.rasterLayerController.clear(), + await this.clearOverlayControllers([ + this.markerController, + this.circleController, + this.polylineController, + this.polygonController, + this.groundImageController, + this.rasterLayerController, ]); }