Skip to content
This repository was archived by the owner on Oct 2, 2019. It is now read-only.

Commit f87f84c

Browse files
committed
Fix tolerance for null or undefined values
1 parent 7f30bcd commit f87f84c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/uiSelectMultipleDirective.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ uis.directive('uiSelectMultiple', ['uiSelectMinErr','$timeout', function(uiSelec
156156
if(!angular.isArray(ngModel.$viewValue)){
157157
// Have tolerance for null or undefined values
158158
if(angular.isUndefined(ngModel.$viewValue) || ngModel.$viewValue === null){
159-
$select.selected = [];
159+
ngModel.$viewValue = [];
160160
} else {
161161
throw uiSelectMinErr('multiarr', "Expected model value to be array but got '{0}'", ngModel.$viewValue);
162162
}

0 commit comments

Comments
 (0)