<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://mywikibiz.com/index.php?action=history&amp;feed=atom&amp;title=Module%3ARfD</id>
	<title>Module:RfD - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://mywikibiz.com/index.php?action=history&amp;feed=atom&amp;title=Module%3ARfD"/>
	<link rel="alternate" type="text/html" href="https://mywikibiz.com/index.php?title=Module:RfD&amp;action=history"/>
	<updated>2026-06-13T22:59:47Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.3</generator>
	<entry>
		<id>https://mywikibiz.com/index.php?title=Module:RfD&amp;diff=479133&amp;oldid=prev</id>
		<title>Zoran: Pywikibot 6.4.0</title>
		<link rel="alternate" type="text/html" href="https://mywikibiz.com/index.php?title=Module:RfD&amp;diff=479133&amp;oldid=prev"/>
		<updated>2021-07-16T05:39:08Z</updated>

		<summary type="html">&lt;p&gt;Pywikibot 6.4.0&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;require('Module:No globals')&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local getTargetFromText = require('Module:Redirect').getTargetFromText&lt;br /&gt;
local messageBox&lt;br /&gt;
&lt;br /&gt;
local mboxText = &amp;quot;%s'''The purpose of this redirect is currently being discussed by the Wikipedia community.&amp;quot;&lt;br /&gt;
	.. &amp;quot; The outcome of the discussion may result in a change of this page, or possibly its deletion in accordance with Wikipedia's [[Wikipedia:Deletion policy|deletion policy]].''' &amp;lt;br /&amp;gt;&amp;quot;&lt;br /&gt;
	.. &amp;quot; Please share your thoughts on the matter at '''[[Wikipedia:Redirects for discussion/Log/%s %s %s#%s|this redirect's entry]]''' on the [[Wikipedia:Redirects for discussion|Redirects for discussion]] page.&amp;lt;br /&amp;gt;&amp;quot;&lt;br /&gt;
	.. &amp;quot;  '''Click on the link below''' to go to the current destination page.&amp;lt;br /&amp;gt;&amp;quot;&lt;br /&gt;
	.. &amp;quot;&amp;lt;small&amp;gt;Please notify the good-faith creator and any main contributors of the redirect by placing &amp;lt;code&amp;gt;&amp;amp;#123;&amp;amp;#123;[[Wikipedia:Substitution|subst]]:[[Template:Rfd notice|Rfd notice]]&amp;amp;#124;%s&amp;amp;#125;&amp;amp;#125; &amp;amp;#126;&amp;amp;#126;&amp;amp;#126;&amp;amp;#126;&amp;lt;/code&amp;gt; on their talk page.&amp;lt;/small&amp;gt;&amp;quot;&lt;br /&gt;
local errorMessage = '&amp;lt;span class=&amp;quot;error&amp;quot;&amp;gt;Error: Unable to determine the redirect\'s target. If this page is a soft redirect, then this error can be ignored. Otherwise, please make sure that [[WP:RFD#HOWTO|the instructions for placing this tag]] were followed correctly, in particular that the redirect\'s old content was passed in the &amp;lt;code&amp;gt;content&amp;lt;/code&amp;gt; parameter.&amp;lt;/span&amp;gt;&amp;lt;br /&amp;gt;'&lt;br /&gt;
local deleteReason = '[[Wikipedia:Redirects for discussion]] debate closed as delete'&lt;br /&gt;
local messageOnTransclusions = '&amp;lt;div class=&amp;quot;boilerplate metadata plainlinks&amp;quot; id=&amp;quot;rfd-t&amp;quot; style=&amp;quot;'&lt;br /&gt;
    .. 'background-color: transparent; padding: 0; font-size:xx-small; color:#000000; text-align:'&lt;br /&gt;
    .. 'center; border-bottom:1px solid #AAAAAA;&amp;quot;&amp;gt;&amp;amp;lsaquo;The [[Wikipedia:Template namespace|template]]'&lt;br /&gt;
    .. ' below is included via a [[Wikipedia:Redirect|redirect]] ([[%s]]) that has been nominated for discussion. '&lt;br /&gt;
    .. 'See [[Wikipedia:Redirects for discussion/Log/%s %s %s#%s|redirects for discussion]] to help reach a consensus' &lt;br /&gt;
    .. ' on what to do.&amp;amp;rsaquo;&amp;lt;/div &amp;gt;'&lt;br /&gt;
local function makeRfdNotice(args)&lt;br /&gt;
	local currentTitle = mw.title.getCurrentTitle()&lt;br /&gt;
	if not messageBox then&lt;br /&gt;
		messageBox = require('Module:Message box')&lt;br /&gt;
	end&lt;br /&gt;
	local discussionPage = args[1] and mw.text.trim(args[1])&lt;br /&gt;
	if discussionPage == '' then&lt;br /&gt;
		discussionPage = nil&lt;br /&gt;
	end&lt;br /&gt;
	local target = getTargetFromText(args.content)&lt;br /&gt;
	local isError = not target or not mw.title.new(target)&lt;br /&gt;
	local category&lt;br /&gt;
	if args.category then&lt;br /&gt;
		category = args.category&lt;br /&gt;
	elseif args.timestamp then&lt;br /&gt;
                -- Extract stable year and month from timestamp; args.month and args.year can change if the discussion is relisted (see [[Special:Diff/896302321]])&lt;br /&gt;
                local lang = mw.language.getContentLanguage()&lt;br /&gt;
                local catMonth = lang:formatDate('F', args.timestamp)&lt;br /&gt;
                local catYear = lang:formatDate('Y', args.timestamp)&lt;br /&gt;
		category = string.format('[[Category:Redirects for discussion from %s %s|%s]][[Category:All redirects for discussion|%s]]', catMonth, catYear, currentTitle.text, currentTitle.text)&lt;br /&gt;
	else&lt;br /&gt;
		category = string.format('[[Category:Redirects for discussion|%s]][[Category:All redirects for discussion|%s]]', currentTitle.text, currentTitle.text)&lt;br /&gt;
	end&lt;br /&gt;
	if category then category = category..'[[Category:Temporary maintenance holdings]]' end&lt;br /&gt;
	return string.format('%s&amp;lt;span id=&amp;quot;delete-reason&amp;quot; style=&amp;quot;display:none;&amp;quot;&amp;gt;%s&amp;lt;/span&amp;gt;%s%s',&lt;br /&gt;
		messageBox.main('mbox', {&lt;br /&gt;
			type = 'delete',&lt;br /&gt;
			name = 'RfD',&lt;br /&gt;
			image = 'none',&lt;br /&gt;
			text = string.format(mboxText, isError and errorMessage or '', args.year, args.month, args.day, discussionPage or currentTitle.prefixedText, mw.text.nowiki(currentTitle.prefixedText))&lt;br /&gt;
		}),&lt;br /&gt;
		mw.uri.encode(deleteReason),&lt;br /&gt;
		category,&lt;br /&gt;
		isError and '[[Category:RfD errors]]' or ''&lt;br /&gt;
	)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
p[''] = function(frame)&lt;br /&gt;
	local args = frame.args&lt;br /&gt;
	if not args.content or mw.text.trim(args.content) == '' then&lt;br /&gt;
		return '&amp;lt;span class=&amp;quot;error&amp;quot;&amp;gt;Error: No content was provided. The original text of the page (the #REDIRECT line and any templates) must be placed inside of the content parameter.[[Category:RfD errors]]&amp;lt;/span&amp;gt;'&lt;br /&gt;
	end&lt;br /&gt;
	local pframe = frame:getParent()&lt;br /&gt;
	if pframe:preprocess('&amp;lt;includeonly&amp;gt;1&amp;lt;/includeonly&amp;gt;') == '1' then&lt;br /&gt;
		-- We're being transcluded, so display the content of our target.&lt;br /&gt;
		local target = getTargetFromText(args.content)&lt;br /&gt;
		if target then&lt;br /&gt;
			target = mw.title.new(target)&lt;br /&gt;
		end&lt;br /&gt;
		local redirect = pframe:getTitle()&lt;br /&gt;
		if target and not target.isRedirect and target ~= redirect then&lt;br /&gt;
			-- We should actually be calling expandTemplate on the grandparent rather than on the parent, but we can't do that yet&lt;br /&gt;
			-- Since we don't have grandparent access, though, it means the thing we're calling doesn't either, so it doesn't really matter yet&lt;br /&gt;
			local parsedTarget = pframe:expandTemplate{title = ':' .. target.prefixedText, args = pframe.args}&lt;br /&gt;
			if frame.args.showontransclusion and not mw.isSubsting() then&lt;br /&gt;
				local discussionPage = args[1] and mw.text.trim(args[1])&lt;br /&gt;
				if not discussionPage or discussionPage == '' then&lt;br /&gt;
					discussionPage = redirect&lt;br /&gt;
				end&lt;br /&gt;
				return messageOnTransclusions:format(redirect, args.year, args.month, args.day, discussionPage) .. parsedTarget&lt;br /&gt;
			else&lt;br /&gt;
				return parsedTarget&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	-- We're not being transcluded, or we can't figure out how to display our target.&lt;br /&gt;
	-- Display the RfD banner.&lt;br /&gt;
	return makeRfdNotice(frame.args) .. '\n' .. frame.args.content&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local substText = &amp;quot;{{&amp;lt;includeonly&amp;gt;safesubst:&amp;lt;/includeonly&amp;gt;#invoke:RfD||%s%s|%s%s\n&amp;quot;&lt;br /&gt;
	.. &amp;quot;&amp;lt;!-- The above content is generated by {{subst:rfd}}. --&amp;gt;\n&amp;lt;!-- End of RFD message. Don't edit anything above here, but feel free to edit below here. --&amp;gt;|content=\n%s\n&amp;quot;&lt;br /&gt;
	.. &amp;quot;&amp;lt;!-- Don't add anything after this line unless you're drafting a disambiguation page or article to replace the redirect. --&amp;gt;\n}}&amp;quot;&lt;br /&gt;
local dateText = 'month = %B\n|day = %e\n|year = %Y\n|time = %R\n|timestamp = %Y%m%d%H%M%S'&lt;br /&gt;
&lt;br /&gt;
-- called during subst when the template is initially placed on the page&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	local titleText&lt;br /&gt;
	local pframe = frame:getParent()&lt;br /&gt;
	local pargs = pframe.args&lt;br /&gt;
	local Date&lt;br /&gt;
	if pargs.days then&lt;br /&gt;
		Date = os.date(dateText, os.time() - 86400*pargs.days)&lt;br /&gt;
	else&lt;br /&gt;
		Date = os.date(dateText)&lt;br /&gt;
	end&lt;br /&gt;
	local retval = string.format(substText, pargs.FULLPAGENAME or pargs[1] or '', pargs.showontransclusion and '|showontransclusion=1' or '', Date, pframe:getTitle() == mw.title.getCurrentTitle().prefixedText and '|category=' or '', pargs.content or '')&lt;br /&gt;
	if mw.isSubsting() then&lt;br /&gt;
		return retval&lt;br /&gt;
	else&lt;br /&gt;
		return frame:expandTemplate{title = 'Template:Error:must be substituted', args = {'rfd'}} .. frame:preprocess(retval)&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Zoran</name></author>
	</entry>
</feed>