Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#9419 closed defect (fixed)

XmlStore.hasAttribute and XmlStore.getValue don't work right for XML attributes

Reported by: Mignon Belongie Owned by: Jared Jurkiewicz
Priority: high Milestone: 1.4
Component: DojoX Data Version: 1.3.0
Keywords: XmlStore hasAttribute getValue Cc:
Blocked By: Blocking:


XmlStore?.hasAttribute(item, name) always returns true if 'name' starts with '@', that is, if it's an XML attribute name. This is because XmlStore?.getValue(item, '@bogus') returns null instead of undefined.

Change History (4)

comment:1 Changed 13 years ago by Jared Jurkiewicz

I believe null is a valid attribute value and XML documents I think always return null, even for unset attributes. I'll look at it, but not sure it's fixable.

comment:2 Changed 13 years ago by Jared Jurkiewicz

Okay, after reading around on behavior of getAttribute, this should be fixable. I introduced a new test for it, and patched the getValue function.

Tested on: IE 7, IE6, FF2, Safari 3.2.3, and Google Chrome fine.

comment:3 Changed 13 years ago by Jared Jurkiewicz

Resolution: fixed
Status: newclosed

(In [18047]) Minor tweak to XmlStore?. fixes #9419

comment:4 Changed 13 years ago by Adam Peller

Milestone: tbd1.4
Note: See TracTickets for help on using tickets.