Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

fix(typeahead): resolves property length of undefined error #2999 #3178

Closed
wants to merge 3 commits into from

Conversation

unkleara
Copy link
Contributor

An error is thrown that matches.length is not defined. So we check if matches is truthy first.

@antoinepairet
Copy link

@unkleara thanks for the PR. Do you think you can write a test for this?

@unkleara
Copy link
Contributor Author

Opps I changed deferred.resolve(['good', 'stuff']); to deferred.resolve(['good1', 'stuff']); to make sure I was logging a correct area. Want me to change that back?

Let me know any adjustments that need to be made. It can be tested other places but it makes most sense testing it within the promise since it's going through that function first.

@antoinepairet
Copy link

Yes please change it back.
Thanks for the test.
We will review it and merge it asap (I am on mobile now, so I cant review proprly)

@stmichael
Copy link

👍 I'm having the same issue. Is there any progress on this issue? I'd really appreciate it, if it could be merged.

@johnnyreilly
Copy link

Is there any update on this? Also causing me issues...

@karianna karianna added this to the 0.13.0 milestone Mar 13, 2015
@chrisirhc chrisirhc self-assigned this Mar 23, 2015
@wesleycho
Copy link
Contributor

Is there a particular reason why it returns as undefined?

@chrisirhc
Copy link
Contributor

There's no reason for expecting that since it's always undefined. I'm removing that expect call as I merge.

@chrisirhc chrisirhc closed this in 950c22c Mar 23, 2015
ayakovlevgh pushed a commit to ayakovlevgh/bootstrap that referenced this pull request Mar 24, 2015
- resolves property length of undefined error by checking value first angular-ui#2999

Fixes angular-ui#2999
Closes angular-ui#3178
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants