marlun78 / number-to-words

Converts a number to words
MIT License
225 stars 76 forks source link

Wrong endings for ordinal numbers from 11 to 13 #7

Closed pilyugin closed 8 years ago

pilyugin commented 8 years ago

Converter returns ordinal numbers with wrong endings:

converter.toOrdinal(11); // => “11st”
converter.toOrdinal(12); // => “12nd”
converter.toOrdinal(13); // => “13rd”

But should be 11th, 12th, 13th.

pilyugin commented 8 years ago

Please see my PR #8 which fixes this bug.