Shorten the logic for hooks, ternary was unnecessary
This commit is contained in:
parent
217a7abc43
commit
a4d44979c6
|
@ -301,9 +301,7 @@ jQuery.extend({
|
||||||
|
|
||||||
// Get the appropriate hook, or the formHook
|
// Get the appropriate hook, or the formHook
|
||||||
// if getSetAttribute is not supported and we have form objects in IE6/7
|
// if getSetAttribute is not supported and we have form objects in IE6/7
|
||||||
hooks = formHook && ( name === "name" || elem.nodeName === "FORM" ) ?
|
hooks = jQuery.attrHooks[ name ] || ( ( name === "name" || elem.nodeName === "FORM" ) && formHook );
|
||||||
jQuery.attrHooks[ name ] || formHook :
|
|
||||||
jQuery.attrHooks[ name ];
|
|
||||||
|
|
||||||
if ( value !== undefined ) {
|
if ( value !== undefined ) {
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue