Module:Join

Jump to navigation Jump to search
Documentation[create] [refresh]
This module has no documentation. If you know how to use this module, please create it.
local p = {}
function p.main(frame)
	local args = require('Module:Arguments').getArgs(frame, {
		wrappers = 'Template:Join'
	})
	return p.second(args)
end

function p.second(args)
	local i = 1
	local sep = " "
	local str = ""
	if args["sep"] ~= nil then
		sep = args["sep"]
	end
	while args[i] ~= nil do
		if i > 1 then
			str = str .. sep
		end
		str = str .. args[i]
		i = i + 1
	end
	return str
end
return p