Module:String2: Difference between revisions

Content deleted Content added
debug
don't trim the separator
Line 76:
p.findlast = function(frame)
local s = mw.text.trim( frame.args[1] or "" )
local sep = mw.text.trim( frame.args[2] or ", " )
localif patternsep == ".*" ..then sep = ", " .. "(.*)"end
local pattern = ".*" .. sep .. "(.*)"
a, b, last = s:find(pattern)
if a then