Module:Convert to eastern arabic numerals: Difference between revisions

Content deleted Content added
Add back compat for now
m Comma "," (U+002C) → Arabic Decimal Separator "٫" (U+066B)
 
(3 intermediate revisions by one other user not shown)
Line 12:
['8'] = '٨',
['9'] = '٩',
['%.'] = ',٫'
}
 
Line 18:
if args == nil then
return 'Error! Arguments provided are null'
end
if args[1] == nil then
return num_str''
end
local num_str = tostring(args[1])
forlocal westernnew_str, eastern_ in= pairsstring.gsub(num_str, '[0-9.]', conversion_table) do
return new_str
num_str = string.gsub(num_str, western, eastern)
end
return num_str
end
 
-- remove after removed from other module
function p.convert_str(num)
return p._convert({num})
end