Module:Inventory slot: Difference between revisions
Update to allow aliases to be pre-split, for better performance; also avoid splitting and stringifying input twice |
No edit summary |
||
| Line 331: | Line 331: | ||
frame.mod = frameText:match( '([^:%]]+):' ) or mod | frame.mod = frameText:match( '([^:%]]+):' ) or mod | ||
local vanilla = { v = 1, vanilla = 1, mc = 1, minecraft = 1 } | local vanilla = { v = 1, vanilla = 1, mc = 1, minecraft = 1 } | ||
if frame.mod | if frame.mod and vanilla[mw.ustring.lower( frame.mod )] or frame.mod == '' then | ||
frame.mod = nil | frame.mod = nil | ||
end | end | ||