Fix unknown entity error on delete

This commit is contained in:
John Firebaugh
2013-05-14 17:23:06 -07:00
parent 6431fca8a3
commit 5b69387ea0
+2 -2
View File
@@ -150,8 +150,8 @@ iD.modes.Select = function(context, selection) {
var s = iD.util.entitySelector(selection);
selection.forEach(function(id) {
var entity = context.entity(id);
if (entity.type === 'relation') {
var entity = context.hasEntity(id);
if (entity && entity.type === 'relation') {
entity.members.forEach(function(member) {
s += ',.' + member.id
});