Module:Sprite: Difference between revisions

No edit summary
No edit summary
Line 86: Line 86:
local ids = mw.loadData( 'Module:Sprite/' .. args.name )
local ids = mw.loadData( 'Module:Sprite/' .. args.name )
local id = mw.text.trim( args[1] or '' )
local id = mw.text.trim( args[1] or '' )
local pos = ids[id] or ids[id:lower():gsub( '%s', '-' )]
local pos = ids[id] or ids[id:lower():gsub( '[%s%+]', '-' )]
if not pos then
if not pos then
category = '[[Category:Pages with missing sprites]]'
category = '[[Category:Pages with missing sprites]]'