Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

calendar.parse() cannot parse numbers properly

#355

Calendar parse method works incorrectly

new Calendar().parse('2010-07-01')
=> Thu Jul 01 2010 00:00:00 GMT+0300 (EEST)

new Calendar().parse('2010-08-01')
=> Tue Dec 01 2009 00:00:00 GMT+0200 (EET)

I think it because of using parseInt() method here http://github.com/rightjs/rightjs-ui/blob/4526edad43bc7b668b61/src/... which treats '08' as octal number. I think it should be toInt(value) or parseInt(num, 10)

Reported by Sergey Avseyev · September 18th, 2010 @ 11:11 AM

State: resolved
Milestone: 2.0.0 Release
Assigned to: MadRabbit MadRabbit

Activity

  1. Sergey Avseyev
    Sergey Avseyev
    • Assigned user set to MadRabbit

    September 18th, 2010 @ 11:12 AM

  2. MadRabbit
    MadRabbit
    • Milestone set to 2.0.0 Release
    • Tag changed from calendar to bug, calendar, ui
    • Milestone order changed from 196625 to 0

    a good point. will you patch it and push on github or you'll wait for me?

    September 18th, 2010 @ 11:17 AM

  3. Sergey Avseyev
  4. MadRabbit
    MadRabbit
    • State changed from new to resolved

    September 18th, 2010 @ 12:35 PM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.