You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
When selecting the empty value <option value=""></option> on a <select multiple="multiple" ng-options="v.label for(k,v) in options"> a type error is thrown.
TypeError: Cannot read property 'disabled' of undefined
at angular.min.js:272
at m (angular.min.js:7)
at u.readValue (angular.min.js:272)
at angular.min.js:285
at n.$eval (angular.min.js:134)
at n.$apply (angular.min.js:135)
at HTMLSelectElement.<anonymous> (angular.min.js:285)
at HTMLSelectElement.Gf.c (angular.min.js:35)
Fix:
Replace
if (!option.disabled) selections.push(options.getViewValueFromOption(option));
with
if (option && !option.disabled) selections.push(options.getViewValueFromOption(option));