Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS8 parse() crashes #55

Closed
jorisroling opened this issue Sep 19, 2014 · 4 comments
Closed

iOS8 parse() crashes #55

jorisroling opened this issue Sep 19, 2014 · 4 comments

Comments

@jorisroling
Copy link

Hi Arnout,

The Useragent string

"Mozilla/5.0 (iPhone; CPU iPhone OS 8_0 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) Version/8.0 Mobile/12A365 Safari/600.1.4"

crashes the parse() function.

I get:
[TypeError: Invalid Version: 8.0.undefined]

Cheers,
Joris

@3rd-Eden
Copy link
Owner

I'm unable to reproduce this, could you check if 2.0.10 resolves these issues for you? I released it a couple of minutes ago.

@jorisroling
Copy link
Author

Hi Arnout,

My bad, I assumed that the structure agent.os.toJSON() returned would always contain a valid patch field, and with iOS8 devices it did not (undefined). I solved it by checking the validity first.

Thanks for you time! (and sorry for wasting it)

J*

@3rd-Eden
Copy link
Owner

@jorisroling Oh, I would actually see that an issue. This library should just provide sane defaults. So 2.1 will default everything 0 as expected.

@jorisroling
Copy link
Author

Cheers!


Sent from Mailbox

On Mon, Sep 22, 2014 at 12:55 PM, Arnout Kazemier
notifications@github.com wrote:

@jorisroling Oh, I would actually see that an issue. This library should just provide sane defaults. So 2.1 will default everything 0 as expected.

Reply to this email directly or view it on GitHub:
#55 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants