<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.vvfh.org/index.php?action=history&amp;feed=atom&amp;title=Module%3AProtected_edit_request</id>
	<title>Module:Protected edit request - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.vvfh.org/index.php?action=history&amp;feed=atom&amp;title=Module%3AProtected_edit_request"/>
	<link rel="alternate" type="text/html" href="https://wiki.vvfh.org/index.php?title=Module:Protected_edit_request&amp;action=history"/>
	<updated>2026-05-15T14:40:58Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.42.1</generator>
	<entry>
		<id>https://wiki.vvfh.org/index.php?title=Module:Protected_edit_request&amp;diff=23300&amp;oldid=prev</id>
		<title>Schmehl: 1 revision imported</title>
		<link rel="alternate" type="text/html" href="https://wiki.vvfh.org/index.php?title=Module:Protected_edit_request&amp;diff=23300&amp;oldid=prev"/>
		<updated>2017-10-28T19:31:10Z</updated>

		<summary type="html">&lt;p&gt;1 revision imported&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;require(&amp;#039;Module:No globals&amp;#039;)&lt;br /&gt;
&lt;br /&gt;
local yesno = require(&amp;#039;Module:Yesno&amp;#039;)&lt;br /&gt;
local makeMessageBox = require(&amp;#039;Module:Message box&amp;#039;).main&lt;br /&gt;
local getArgs&lt;br /&gt;
&lt;br /&gt;
local activeBox -- lazily initialized if we get an active request&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------&lt;br /&gt;
-- Box class definition&lt;br /&gt;
----------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local box = {}&lt;br /&gt;
box.__index = box&lt;br /&gt;
&lt;br /&gt;
function box.new(protectionType, args)&lt;br /&gt;
	local obj = {}&lt;br /&gt;
	setmetatable(obj, box)&lt;br /&gt;
	obj.tmboxArgs = {} -- Used to store arguments to be passed to tmbox by the box:export method.&lt;br /&gt;
	-- Set data fields.&lt;br /&gt;
	obj.tmboxArgs.attrs = { [&amp;#039;data-origlevel&amp;#039;] = protectionType }&lt;br /&gt;
	return obj&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function box:setArg(key, value)&lt;br /&gt;
	-- This sets a value to be passed to tmbox.&lt;br /&gt;
	if key then&lt;br /&gt;
		self.tmboxArgs[key] = value&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function box:export()&lt;br /&gt;
	self:setArg(&amp;#039;smalltext&amp;#039;, &amp;quot;This [[Wikipedia:Edit requests|edit request]] has been answered. Set the &amp;lt;code style=\&amp;quot;white-space: nowrap;\&amp;quot;&amp;gt;&amp;amp;#124;answered&amp;amp;#61;&amp;lt;/code&amp;gt; or &amp;lt;code style=\&amp;quot;white-space: nowrap;\&amp;quot;&amp;gt;&amp;amp;#124;ans&amp;amp;#61;&amp;lt;/code&amp;gt; parameter to &amp;#039;&amp;#039;&amp;#039;no&amp;#039;&amp;#039;&amp;#039; to reactivate your request.&amp;quot;)&lt;br /&gt;
	self:setArg(&amp;#039;small&amp;#039;, true)&lt;br /&gt;
	self:setArg(&amp;#039;class&amp;#039;, &amp;#039;editrequest&amp;#039;)&lt;br /&gt;
	return makeMessageBox(&amp;#039;tmbox&amp;#039;, self.tmboxArgs)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
----------------------------------------------------------------------&lt;br /&gt;
-- Process arguments and initialise objects&lt;br /&gt;
----------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
function p._main(protectionType, args)&lt;br /&gt;
	local boxType = box&lt;br /&gt;
	if not yesno(args.answered or args.ans, true) then&lt;br /&gt;
		if not activeBox then&lt;br /&gt;
			activeBox = require(&amp;#039;Module:Protected edit request/active&amp;#039;)(box, yesno, makeMessageBox)&lt;br /&gt;
		end&lt;br /&gt;
		boxType = activeBox&lt;br /&gt;
	end&lt;br /&gt;
	local requestBox = boxType.new(protectionType, args)&lt;br /&gt;
	return requestBox:export()&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local mt = {}&lt;br /&gt;
&lt;br /&gt;
function mt.__index(t, k)&lt;br /&gt;
	if not getArgs then&lt;br /&gt;
		getArgs = require(&amp;#039;Module:Arguments&amp;#039;).getArgs&lt;br /&gt;
	end&lt;br /&gt;
	return function (frame)&lt;br /&gt;
		return t._main(k, getArgs(frame, {wrappers = {&amp;#039;Template:Edit fully-protected&amp;#039;, &amp;#039;Template:Edit semi-protected&amp;#039;, &amp;#039;Template:Edit template-protected&amp;#039;, &amp;#039;Template:Edit extended-protected&amp;#039;}}))&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return setmetatable(p, mt)&lt;/div&gt;</summary>
		<author><name>Schmehl</name></author>
	</entry>
</feed>