Skip to content

Commit 16170ce

Browse files
committed
Use underscore to fetch selected values as array
1 parent ca9e33f commit 16170ce

File tree

1 file changed

+1
-1
lines changed
  • app/code/Magento/Ui/view/base/web/js/form

1 file changed

+1
-1
lines changed

app/code/Magento/Ui/view/base/web/js/form/form.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ define([
5656

5757
case 'select-multiple':
5858
var name = item.name.substring(0,(item.name.length - 2)); //remove [] from the name ending
59-
result[name] = Array.prototype.slice.call(item.selectedOptions).map(function(o) {return o.value;});
59+
result[name] = _.pluck(item.selectedOptions, 'value');
6060
break;
6161

6262
default:

0 commit comments

Comments
 (0)