Module:Abilities/utils: Difference between revisions

m Fix double negatives
m Only add plus prefix if it is explicitly defined in localization file
Line 50: Line 50:
prefix = '+'
prefix = '+'
end
end
-- ONLY add a '+' if the value is positive AND there isn't already a prefix.
elseif (type(value) == 'number' and value > 0 and prefix == '') then
prefix = '+'
end
end