Skip to content

Commit 2a3ec95

Browse files
Merge pull request #491 from bobjoe400/pluarize-with-big-num-fix
Added check for if to_number returns a string within pluralize. - seems to add some compat with omega_num with some jokers to so ig thats a plus
2 parents 4ebd1d4 + 831f3ac commit 2a3ec95

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/misc.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,7 @@ function Cryptid.pluralize(str, vars)
184184
table.insert(_table, v)
185185
end
186186
local num = vars[tonumber(string.match(str, ">(%d+)"))] -- gets reference variable
187+
if type(num) == 'string' then num = (Big and to_number(to_big(num))) or num end
187188
local plural = _table[1] -- default
188189
local checks = { [1] = "=" } -- checks 1 by default
189190
local checks1mod = false -- tracks if 1 was modified

0 commit comments

Comments
 (0)