Studio: fix failing detection, add error message after reddit post
This commit is contained in:
parent
7677788a02
commit
bd58adc373
2 changed files with 6 additions and 2 deletions
|
@ -170,8 +170,12 @@ export class Tag extends TagsFilter {
|
||||||
return <any>this
|
return <any>this
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* new Tag("panoramax", "").isNegative() // => true
|
||||||
|
* new Tag("x","y").isNegative() // => false
|
||||||
|
*/
|
||||||
isNegative(): boolean {
|
isNegative(): boolean {
|
||||||
return false
|
return this.value === ""
|
||||||
}
|
}
|
||||||
|
|
||||||
visit(f: (tagsFilter: TagsFilter) => void) {
|
visit(f: (tagsFilter: TagsFilter) => void) {
|
||||||
|
|
|
@ -69,7 +69,7 @@ export class PrevalidateLayer extends DesugaringStep<LayerConfigJson> {
|
||||||
context
|
context
|
||||||
.enters("source", "osmTags")
|
.enters("source", "osmTags")
|
||||||
.err(
|
.err(
|
||||||
"The source states tags which give a very wide selection: it only uses negative expressions, which will result in too much and unexpected data. Add at least one required tag. The tags are:\n\t" +
|
"The tags that will be used to load data from OpenStreetMap are all negative - this means that they all match something that _doesn't_ have a certain tag. For example, `key=` means anything without `key`. Did you perhaps mean to use `key~*`, meaning anything _with_ this key set? The tags are:\n\t" +
|
||||||
osmTags.asHumanString(false, false, {})
|
osmTags.asHumanString(false, false, {})
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue