osrec / currencyFormatter.js

A super simple currency formatting library
MIT License
633 stars 61 forks source link

Library crash when the pattern doesn't contain dots #11

Closed Frzurita closed 6 years ago

Frzurita commented 7 years ago

the error is in the line 1179, the var segment should be declare out of if statement. Otherwise the library crash because it is trying to get the length of undefined

osrec commented 7 years ago

Ah, thank you - good spot. We will fix and issue a release shortly :)

Vebby

Frzurita commented 6 years ago

thanks! great library by the way 👍

osrec commented 6 years ago

Fixed now in latest version (v2.0.0) :)