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

set default value to empty array #251

Merged
merged 2 commits into from
Mar 16, 2017
Merged

Conversation

ivanvoznyakovsky
Copy link
Contributor

in case if items source is not defined in $scope when initializing multiselect instance of ui-select, we'll get an undefined from ctrl.parserResult.source($scope). then next line will throw an exception when truing to filter undefined.

@dimirc dimirc added this to the 0.8.x milestone Oct 10, 2014
@dimirc dimirc removed this from the 0.8.x milestone Feb 16, 2015
@aaronroberson
Copy link
Contributor

@ivanvoznyakovsky Can you update this PR in the uiSelectController.js file (~ line 197)?

@Jefiozie
Copy link
Contributor

@ivanvoznyakovsky as @aaronroberson mentioned above can you fix this PR?

@ivanvoznyakovsky
Copy link
Contributor Author

ivanvoznyakovsky commented Jan 25, 2017

sorry. totally missed previous notification.
looks like the case I've described is already handled but I found another one related to the same situation when items source is not defined.
updating

@ivanvoznyakovsky ivanvoznyakovsky force-pushed the master branch 2 times, most recently from 7e09b13 to d8b3fd5 Compare January 25, 2017 20:39
in case if items source is not defined in $scope when initializing multiselect instance of ui-select, we'll get an undefined from ctrl.parserResult.source($scope). then next line will throw an exception when truing to filter undefined.
@Jefiozie
Copy link
Contributor

@ivanvoznyakovsky thanks for the commit. Can you make a unit test for this?

@ivanvoznyakovsky
Copy link
Contributor Author

@Jefiozie added tests

@Jefiozie Jefiozie assigned Jefiozie and unassigned Jefiozie Feb 21, 2017
@Jefiozie Jefiozie self-requested a review February 21, 2017 20:25
@Jefiozie Jefiozie added this to the v0.19.6 milestone Mar 9, 2017
@Jefiozie Jefiozie merged commit 55cfc23 into angular-ui:master Mar 16, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants