Remove value check from formHook; other elements can use value hook

This commit is contained in:
timmywil 2011-05-07 22:01:10 -04:00
parent 90f37aaf7a
commit 18b1cf2942
2 changed files with 3 additions and 4 deletions

View file

@ -495,9 +495,6 @@ if ( !jQuery.support.getSetAttribute ) {
formHook = jQuery.attrHooks.name = jQuery.attrHooks.value = jQuery.valHooks.button = {
get: function( elem, name ) {
var ret;
if ( name === "value" && !jQuery.nodeName( elem, "button" ) ) {
return elem.getAttribute( name );
}
ret = elem.getAttributeNode( name );
// Return undefined if nodeValue is empty string
return ret && ret.nodeValue !== "" ?