40 points · by mvrekic · 14y ago · 19 comments
That pedantry aside, it seems like a decent enough chunk of code, and it's very easy to read. More libraries should be this clean.
EDIT: Actually having now looked at the code, it seems a lot of it is specifically using the phpjs library.
filesizeformat (1234567890 = 1.15 Gb)
This should be either 9.20 Gb or 1.15 GB. => Humanize.truncatechars("<script>alert('yo');<\/script>", 30)
"<script>alert('yo');</script>"
=> Humanize.linebreaks("<script>alert('yo');<\/script>")
"<p><script>alert('yo');</script></p>"
Bug filed.1) Gb should be GiB
2) it would be lovely to see some internationalisation support.
Don't know why this has happened to you...