298
edits
m (support "suffix:") |
(Add additional condition to displayimage addition to prevent string.len error with nil) |
||
Line 90: | Line 90: | ||
local img = displayimg | local img = displayimg | ||
if string.len(displayimg) > 4 then | if displayimg ~= nil then | ||
if string.len(displayimg) > 4 then | |||
if string.sub(displayimg, -4) == '.png' then | |||
img = '[[File:' .. displayimg.. '|16px|link='..pagelink..']]' | |||
end | |||
end | end | ||
end | end |