Skip to content

Commit cab1835

Browse files
committed
Attrs: Simplify an option hook
Since getter was removed in fdd78fa there is no longer a need to wrap option element in order to get its value Fixes #14756
1 parent cd4e25e commit cab1835

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/attributes/val.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ jQuery.extend({
117117

118118
while ( i-- ) {
119119
option = options[ i ];
120-
if ( (option.selected = jQuery.inArray( jQuery(option).val(), values ) >= 0) ) {
120+
if ( (option.selected = jQuery.inArray( option.value, values ) >= 0) ) {
121121
optionSet = true;
122122
}
123123
}

0 commit comments

Comments
 (0)