Module:User:Kephir/test2

* {{#invoke:User:Kephir/test2|count}}
* {{#invoke:User:Kephir/test2|count}}
* {{#invoke:User:Kephir/test2|count}}
* {{#invoke:User:Kephir/test2|count}}
* {{#invoke:User:Kephir/test2|count}}
  • 1
  • 1
  • 1
  • 1
  • 1
{{#invoke:User:Kephir/test2|bailout}}

Boo! asdf


local export = {}

local i = 0

function export.count(frame)
	i = i + 1
	return i
end

function export.get_page(frame)
	local title = mw.title.new(frame.args[1])
	return title:getContent()
end

function export.bailout(frame)
	return(setmetatable({
		"asdf"
	}, {
		__tostring = function (self)
			return "Boo! " .. self[1]
		end
	}))
end

return export