mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-21 07:46:58 +02:00
Add explict check for prototype inheritance of entities Chrome bug
(see #3973)
This commit is contained in:
@@ -34,6 +34,12 @@ coreGraph.prototype = {
|
||||
|
||||
entity: function(id) {
|
||||
var entity = this.entities[id];
|
||||
|
||||
//https://github.com/openstreetmap/iD/issues/3973#issuecomment-307052376
|
||||
if (!entity) {
|
||||
entity = this.entities.__proto__[id];
|
||||
}
|
||||
|
||||
if (!entity) {
|
||||
throw new Error('entity ' + id + ' not found');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user