user/uid can be undefined for all types

This commit is contained in:
John Firebaugh
2013-03-12 17:47:50 -07:00
parent 76ab27ae4c
commit 42ff0f359a

View File

@@ -81,8 +81,8 @@ iD.Connection = function(context) {
id: iD.Entity.id.fromOSM(wayStr, attrs.id.nodeValue),
version: attrs.version.nodeValue,
changeset: attrs.changeset.nodeValue,
user: attrs.user.nodeValue,
uid: attrs.uid.nodeValue,
user: attrs.user && attrs.user.nodeValue,
uid: attrs.uid && attrs.uid.nodeValue,
visible: attrs.visible.nodeValue,
timestamp: attrs.timestamp.nodeValue,
tags: getTags(obj),
@@ -96,8 +96,8 @@ iD.Connection = function(context) {
id: iD.Entity.id.fromOSM(relationStr, attrs.id.nodeValue),
version: attrs.version.nodeValue,
changeset: attrs.changeset.nodeValue,
user: attrs.user.nodeValue,
uid: attrs.uid.nodeValue,
user: attrs.user && attrs.user.nodeValue,
uid: attrs.uid && attrs.uid.nodeValue,
visible: attrs.visible.nodeValue,
timestamp: attrs.timestamp.nodeValue,
tags: getTags(obj),