Open
Description
- I'm submitting a Bug
- bug report
-
feature request - support / question
Brief Description
Loading of some changesets fails.
What is the current behaviour, (attach relevant screenshots) ?
TypeError: Cannot read property 'toString' of null
What is the expected behaviour ?
A better error message or maybe no error at all.
When does this occur ?
When the changeset has no closed_at property.
How do we replicate the issue ?
Example changeset: https://www.openstreetmap.org/api/0.6/changeset/109618303.json?include_discussion=true
Other Information / context:
c.to
can be null
Line 21 in df4dbcb
(null).toString()
does not workchangeset-map/lib/getChangeset.js
Line 79 in df4dbcb
Possible solutions:
- Better error message
var data = getDataParam(changeset);
+ if (!data.to) {
+ new Error('Changeset has no closed_at property!')
+ }
- Not returning null.
- to: cs.closed_at || null,
+ to: cs.closed_at || …,
Metadata
Metadata
Assignees
Labels
No labels