Allow missing base layer query param for highlight

This commit is contained in:
Maciej Ziarkowski 2019-09-17 18:19:21 +01:00
parent 9fd690c1ac
commit fe3f02bd85

View File

@ -108,8 +108,9 @@ function getHighlightDataConfig(tileset: string, dataParams: any): DataConfig {
let { highlight, base } = dataParams; let { highlight, base } = dataParams;
highlight = strictParseInt(highlight); highlight = strictParseInt(highlight);
base = base || 'default';
if(isNaN(highlight) || base == undefined || base.match(/^\w+$/) == undefined) { if(isNaN(highlight) || base.match(/^\w+$/) == undefined) {
throw new Error('Bad parameters for highlight layer'); throw new Error('Bad parameters for highlight layer');
} }