Skip to content

Commit c7c37f6

Browse files
committed
[ut] fix ut
(reviewed by xjj)
1 parent ac9e78c commit c7c37f6

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/common/mapping/WebMapV3.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ export function createWebMapV3Extending(SuperClass, { MapManager, mapRepo, crsMa
436436
const mapboxSourceIds = mapboxglLayers.map((layer) => layer.source);
437437
for(const sourceId of mapboxSourceIds) {
438438
const source = sources[sourceId];
439-
if(source.type === 'geojson' && source.data?.type === 'supermap-rest-data') {
439+
if(source && source.type === 'geojson' && source.data && source.data.type === 'supermap-rest-data') {
440440
source.data = await l7LayerUtil.getRestDataGeojsonByWebMap(source.data, {iportalServiceProxyUrlPrefix: this.options.server, withoutFormatSuffix: true});
441441
}
442442
}

0 commit comments

Comments
 (0)