File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -232,14 +232,14 @@ export class Map extends maplibregl.Map {
232232 } ) ;
233233 }
234234
235- private setSpaceFromStyle ( { style } : { style ? : StyleSpecificationWithMetaData } ) {
235+ private setSpaceFromStyle ( { style } : { style : StyleSpecificationWithMetaData } ) {
236236 if ( ! style ?. metadata ?. maptiler ?. space ) {
237237 return ;
238238 }
239239 this . space ?. setCubemap ( style . metadata . maptiler . space ) ;
240240 }
241241
242- private setHaloFromStyle ( { style } : { style ? : StyleSpecificationWithMetaData } ) {
242+ private setHaloFromStyle ( { style } : { style : StyleSpecificationWithMetaData } ) {
243243 if ( ! style ?. metadata ?. maptiler ?. halo ) {
244244 return ;
245245 }
@@ -959,13 +959,15 @@ export class Map extends maplibregl.Map {
959959
960960 if ( typeof styleInfo . style !== "string" && ! styleInfo . requiresUrlMonitoring ) {
961961 if ( this . space ) {
962- this . setSpaceFromStyle ( { style } ) ;
962+ const styleWithMetaData = styleInfo . style as StyleSpecificationWithMetaData ;
963+ this . setSpaceFromStyle ( { style : styleWithMetaData } ) ;
963964 } else {
964965 this . initSpace ( { before } ) ;
965966 }
966967
967968 if ( this . halo ) {
968- this . setHaloFromStyle ( { style } ) ;
969+ const styleWithMetaData = styleInfo . style as StyleSpecificationWithMetaData ;
970+ this . setHaloFromStyle ( { style : styleWithMetaData } ) ;
969971 } else {
970972 this . initHalo ( { before } ) ;
971973 }
You can’t perform that action at this time.
0 commit comments