forked from MapComplete/MapComplete
chore: automated housekeeping...
This commit is contained in:
parent
9cd7ad597d
commit
69ab755f29
520 changed files with 16616 additions and 13483 deletions
|
|
@ -16,8 +16,7 @@ export class HistogramViz extends SpecialVisualization {
|
|||
name: "key",
|
||||
doc: "The key to be read and to generate a histogram from",
|
||||
required: true,
|
||||
}
|
||||
|
||||
},
|
||||
]
|
||||
|
||||
structuredExamples(): { feature: Feature; args: string[] }[] {
|
||||
|
|
@ -47,12 +46,17 @@ export class HistogramViz extends SpecialVisualization {
|
|||
if (value === "" || value === undefined) {
|
||||
return undefined
|
||||
}
|
||||
if(Array.isArray(value)){
|
||||
if (Array.isArray(value)) {
|
||||
return value
|
||||
}
|
||||
return JSON.parse(value)
|
||||
} catch (e) {
|
||||
console.error("Could not load histogram: parsing of the list failed: ", e,"\nthe data to parse is",value)
|
||||
console.error(
|
||||
"Could not load histogram: parsing of the list failed: ",
|
||||
e,
|
||||
"\nthe data to parse is",
|
||||
value
|
||||
)
|
||||
return undefined
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue