Skip to content

Commit 7830290

Browse files
jasonthomasgrayJefiozie
authored andcommitted
fix(lockedItems): Properly unlock locked items when lock conditions change
Previously when the lock expression value changes from true to false the locked value was not removed from the locked list. Closes angular-ui#1824
1 parent aaed73e commit 7830290

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/uiSelectController.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ uis.controller('uiSelectCtrl',
430430
ctrl.close(skipFocusser);
431431
return;
432432
}
433-
}
433+
}
434434
_resetSearchInput();
435435
$scope.$broadcast('uis:select', item);
436436

@@ -509,7 +509,7 @@ uis.controller('uiSelectCtrl',
509509
}
510510

511511
if (!isLocked && lockedItemIndex > -1) {
512-
lockedItems.splice(lockedItemIndex, 0);
512+
lockedItems.splice(lockedItemIndex, 1);
513513
}
514514
}
515515

0 commit comments

Comments
 (0)