GPX read should allow for blank attribute nodes
This commit is contained in:
@@ -197,7 +197,7 @@ OpenLayers.Format.GPX = OpenLayers.Class(OpenLayers.Format.XML, {
|
|||||||
var attributes = {};
|
var attributes = {};
|
||||||
var attrNode = node.firstChild, value, name;
|
var attrNode = node.firstChild, value, name;
|
||||||
while(attrNode) {
|
while(attrNode) {
|
||||||
if(attrNode.nodeType == 1) {
|
if(attrNode.nodeType == 1 && attrNode.firstChild) {
|
||||||
value = attrNode.firstChild;
|
value = attrNode.firstChild;
|
||||||
if(value.nodeType == 3 || value.nodeType == 4) {
|
if(value.nodeType == 3 || value.nodeType == 4) {
|
||||||
name = (attrNode.prefix) ?
|
name = (attrNode.prefix) ?
|
||||||
|
|||||||
Reference in New Issue
Block a user