r-anime / misato

💬 Mod bot for the /r/anime Discord
MIT License
6 stars 7 forks source link

Fix output of the convert command #187

Closed mushroom-disaster closed 2 years ago

mushroom-disaster commented 2 years ago

I got around the issue by dynamically setting the precision of toFixed() depending on how many zeroes are present after the decimal point in the result. So if there are three zeroes after the decimal point, the precision would be two more than that. Fixes #186