Numbers#formatThousandsUnit does not format with maxfractions if number < base #251

Closed
jepsar opened this Issue May 18, 2016 · 3 comments

Projects

None yet

2 participants

@jepsar
jepsar commented May 18, 2016

of:formatThousandsUnit('2.3333333333333','W') ends up as 2.3333333333333 W, while 2.33 Wis expected.

@BalusC
Member
BalusC commented May 21, 2016

Fixed along with #252

@BalusC BalusC closed this May 21, 2016
@BalusC
Member
BalusC commented May 21, 2016

Initially, values lower than 1000 are unaffected, as documented. I however agree that this is not nice. Now values lower than 1000 are formatted too, including 999.999 which becomes 1k. Improvement is available in today's 2.4 snapshot. Thank you for reporting and improving OmniFaces!

@jepsar
jepsar commented May 23, 2016

Yeah, the original code was designed to handle bytes (integers), that's probably how this must have slipped in. Thanks for fixing!

@jepsar jepsar changed the title from Numbers#formatThousandsUnit does not formats with maxfractions if number < base to Numbers#formatThousandsUnit does not format with maxfractions if number < base May 23, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment