Module:Addlink

local p = {}

function p.getTargetFromText(frame) local text = frame.args[1] return string.match(frame, "^%[%[") end

function p.wrapInLink(frame) local text = frame.args[1] if string.match(text, "^%[%[") ~= nil then return text end

return  .. text ..  end

return p