mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-17 22:24:49 +02:00
Save originals of parent entities to localstorage
This prevents strange things from happening when a way is moved, (affecting only the childnodes but not the way).
This commit is contained in:
@@ -199,6 +199,12 @@ iD.History = function(context) {
|
||||
if (id in base.graph.entities) {
|
||||
baseEntities[id] = base.graph.entities[id];
|
||||
}
|
||||
// get originals of parent entities too
|
||||
_.forEach(base.graph._parentWays[id], function(parentId) {
|
||||
if (parentId in base.graph.entities) {
|
||||
baseEntities[parentId] = base.graph.entities[parentId];
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
var x = {};
|
||||
|
||||
Reference in New Issue
Block a user