From fe3f02bd85af3897c6921555366a998acac6a26d Mon Sep 17 00:00:00 2001 From: Maciej Ziarkowski Date: Tue, 17 Sep 2019 18:19:21 +0100 Subject: [PATCH] Allow missing base layer query param for highlight --- app/src/tiles/dataDefinition.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/tiles/dataDefinition.ts b/app/src/tiles/dataDefinition.ts index bdcd5dd5..7977edc6 100644 --- a/app/src/tiles/dataDefinition.ts +++ b/app/src/tiles/dataDefinition.ts @@ -108,8 +108,9 @@ function getHighlightDataConfig(tileset: string, dataParams: any): DataConfig { let { highlight, base } = dataParams; 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'); }