<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://mbwiki.stairwaygames.work/w/index.php?action=history&amp;feed=atom&amp;title=Module%3ANamespace_detect</id>
	<title>Module:Namespace detect - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://mbwiki.stairwaygames.work/w/index.php?action=history&amp;feed=atom&amp;title=Module%3ANamespace_detect"/>
	<link rel="alternate" type="text/html" href="https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;action=history"/>
	<updated>2026-04-06T15:20:45Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;diff=6963&amp;oldid=prev</id>
		<title>Admin coral island at 15:16, 9 August 2023</title>
		<link rel="alternate" type="text/html" href="https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;diff=6963&amp;oldid=prev"/>
		<updated>2023-08-09T15:16:06Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 15:16, 9 August 2023&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;-- &amp;lt;nowiki&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--[[&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--[[&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--------------------------------------------------------------------------------&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--------------------------------------------------------------------------------&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l16&quot;&gt;Line 16:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local data = mw.&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;title.new&lt;/del&gt;( &amp;#039;Module:Namespace &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;detect/data&amp;#039;).exists and mw.loadData(&amp;#039;Module:Namespacce &lt;/del&gt;detect/data&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local data = mw.&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;loadData&lt;/ins&gt;(&amp;#039;Module:Namespace detect/data&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local argKeys = data.argKeys&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local argKeys = data.argKeys&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local cfg = data.cfg&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local cfg = data.cfg&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local mappings = data.mappings&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local mappings = data.mappings&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local yesno = require(&amp;#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Dev&lt;/del&gt;:Yesno&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local yesno = require(&amp;#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Module&lt;/ins&gt;:Yesno&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local mArguments -- Lazily initialise Module:Arguments&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local mArguments -- Lazily initialise Module:Arguments&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local mTableTools -- Lazily initilalise Module:TableTools&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local mTableTools -- Lazily initilalise Module:TableTools&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l131&quot;&gt;Line 131:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 130:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;function p.main(frame)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;function p.main(frame)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	mArguments = require(&amp;#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Dev&lt;/del&gt;:Arguments&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	mArguments = require(&amp;#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Module&lt;/ins&gt;:Arguments&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local args = mArguments.getArgs(frame, {removeBlanks = false})&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local args = mArguments.getArgs(frame, {removeBlanks = false})&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local ret = p._main(args)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local ret = p._main(args)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l145&quot;&gt;Line 145:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 144:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Load modules and initialise variables.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	-- Load modules and initialise variables.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	mTableTools = require(&amp;#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Dev&lt;/del&gt;:TableTools&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	mTableTools = require(&amp;#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Module&lt;/ins&gt;:TableTools&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local namespaces = mw.site.namespaces&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local namespaces = mw.site.namespaces&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local cfg = data.cfg&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;	local cfg = data.cfg&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key new_wiki-coral_islands:diff::1.12:old-6960:rev-6963 --&gt;
&lt;/table&gt;</summary>
		<author><name>Admin coral island</name></author>
	</entry>
	<entry>
		<id>https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;diff=6960&amp;oldid=prev</id>
		<title>Admin coral island at 15:12, 9 August 2023</title>
		<link rel="alternate" type="text/html" href="https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;diff=6960&amp;oldid=prev"/>
		<updated>2023-08-09T15:12:44Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 15:12, 9 August 2023&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l16&quot;&gt;Line 16:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 16:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;--]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local data = mw.title.new( &amp;#039;Module:Namespace detect/data&amp;#039;).exists and mw.loadData(&amp;#039;Module:&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Namespace detect/data&amp;#039;) or mw.loadData(&amp;#039;Dev:Namespace &lt;/del&gt;detect/data&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local data = mw.title.new( &amp;#039;Module:Namespace detect/data&amp;#039;).exists and mw.loadData(&amp;#039;Module:&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Namespacce &lt;/ins&gt;detect/data&amp;#039;)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local argKeys = data.argKeys&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local argKeys = data.argKeys&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local cfg = data.cfg&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;local cfg = data.cfg&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Admin coral island</name></author>
	</entry>
	<entry>
		<id>https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;diff=5701&amp;oldid=prev</id>
		<title>Admin coral island: Created page with &quot;-- &lt;nowiki&gt; --[[ -------------------------------------------------------------------------------- --                                                                            -- --                            NAMESPACE DETECT                                -- --                                                                            -- -- This module implements the {{namespace detect}} template in Lua, with a    -- -- few improvements: all namespaces and all namespace...&quot;</title>
		<link rel="alternate" type="text/html" href="https://mbwiki.stairwaygames.work/w/index.php?title=Module:Namespace_detect&amp;diff=5701&amp;oldid=prev"/>
		<updated>2023-08-04T03:08:10Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;-- &amp;lt;nowiki&amp;gt; --[[ -------------------------------------------------------------------------------- --                                                                            -- --                            NAMESPACE DETECT                                -- --                                                                            -- -- This module implements the {{namespace detect}} template in Lua, with a    -- -- few improvements: all namespaces and all namespace...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;-- &amp;lt;nowiki&amp;gt;&lt;br /&gt;
--[[&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
--                                                                            --&lt;br /&gt;
--                            NAMESPACE DETECT                                --&lt;br /&gt;
--                                                                            --&lt;br /&gt;
-- This module implements the {{namespace detect}} template in Lua, with a    --&lt;br /&gt;
-- few improvements: all namespaces and all namespace aliases are supported,  --&lt;br /&gt;
-- and namespace names are detected automatically for the local wiki. The     --&lt;br /&gt;
-- module can also use the corresponding subject namespace value if it is     --&lt;br /&gt;
-- used on a talk page. Parameter names can be configured for different wikis --&lt;br /&gt;
-- by altering the values in the &amp;quot;cfg&amp;quot; table in                               --&lt;br /&gt;
-- Module:Namespace detect/config.                                            --&lt;br /&gt;
--                                                                            --&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
--]]&lt;br /&gt;
&lt;br /&gt;
local data = mw.title.new( &amp;#039;Module:Namespace detect/data&amp;#039;).exists and mw.loadData(&amp;#039;Module:Namespace detect/data&amp;#039;) or mw.loadData(&amp;#039;Dev:Namespace detect/data&amp;#039;)&lt;br /&gt;
local argKeys = data.argKeys&lt;br /&gt;
local cfg = data.cfg&lt;br /&gt;
local mappings = data.mappings&lt;br /&gt;
&lt;br /&gt;
local yesno = require(&amp;#039;Dev:Yesno&amp;#039;)&lt;br /&gt;
local mArguments -- Lazily initialise Module:Arguments&lt;br /&gt;
local mTableTools -- Lazily initilalise Module:TableTools&lt;br /&gt;
local ustringLower = mw.ustring.lower&lt;br /&gt;
&lt;br /&gt;
local p = {}&lt;br /&gt;
&lt;br /&gt;
local function fetchValue(t1, t2)&lt;br /&gt;
	-- Fetches a value from the table t1 for the first key in array t2 where&lt;br /&gt;
	-- a non-nil value of t1 exists.&lt;br /&gt;
	for i, key in ipairs(t2) do&lt;br /&gt;
		local value = t1[key]&lt;br /&gt;
		if value ~= nil then&lt;br /&gt;
			return value&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return nil&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function equalsArrayValue(t, value)&lt;br /&gt;
	-- Returns true if value equals a value in the array t. Otherwise&lt;br /&gt;
	-- returns false.&lt;br /&gt;
	for i, arrayValue in ipairs(t) do&lt;br /&gt;
		if value == arrayValue then&lt;br /&gt;
			return true&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	return false&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.getPageObject(page)&lt;br /&gt;
	-- Get the page object, passing the function through pcall in case of&lt;br /&gt;
	-- errors, e.g. being over the expensive function count limit.&lt;br /&gt;
	if page then&lt;br /&gt;
		local success, pageObject = pcall(mw.title.new, page)&lt;br /&gt;
		if success then&lt;br /&gt;
			return pageObject&lt;br /&gt;
		else&lt;br /&gt;
			return nil&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		return mw.title.getCurrentTitle()&lt;br /&gt;
	end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Provided for backward compatibility with other modules&lt;br /&gt;
function p.getParamMappings()&lt;br /&gt;
	return mappings&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getNamespace(args)&lt;br /&gt;
	-- This function gets the namespace name from the page object.&lt;br /&gt;
	local page = fetchValue(args, argKeys.demopage)&lt;br /&gt;
	if page == &amp;#039;&amp;#039; then&lt;br /&gt;
		page = nil&lt;br /&gt;
	end&lt;br /&gt;
	local demospace = fetchValue(args, argKeys.demospace)&lt;br /&gt;
	if demospace == &amp;#039;&amp;#039; then&lt;br /&gt;
		demospace = nil&lt;br /&gt;
	end&lt;br /&gt;
	local subjectns = fetchValue(args, argKeys.subjectns)&lt;br /&gt;
	local ret&lt;br /&gt;
	if demospace then&lt;br /&gt;
		-- Handle &amp;quot;demospace = main&amp;quot; properly.&lt;br /&gt;
		if equalsArrayValue(argKeys.main, ustringLower(demospace)) then&lt;br /&gt;
			ret = mw.site.namespaces[0].name&lt;br /&gt;
		else&lt;br /&gt;
			ret = demospace&lt;br /&gt;
		end&lt;br /&gt;
	else&lt;br /&gt;
		local pageObject = p.getPageObject(page)&lt;br /&gt;
		if pageObject then&lt;br /&gt;
			if pageObject.isTalkPage then&lt;br /&gt;
				-- Get the subject namespace if the option is set,&lt;br /&gt;
				-- otherwise use &amp;quot;talk&amp;quot;.&lt;br /&gt;
				if yesno(subjectns) then&lt;br /&gt;
					ret = mw.site.namespaces[pageObject.namespace].subject.name&lt;br /&gt;
				else&lt;br /&gt;
					ret = &amp;#039;talk&amp;#039;&lt;br /&gt;
				end&lt;br /&gt;
			else&lt;br /&gt;
				ret = pageObject.nsText&lt;br /&gt;
			end&lt;br /&gt;
		else&lt;br /&gt;
			return nil -- return nil if the page object doesn&amp;#039;t exist.&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	ret = ret:gsub(&amp;#039;_&amp;#039;, &amp;#039; &amp;#039;)&lt;br /&gt;
	return ustringLower(ret)&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p._main(args)&lt;br /&gt;
	-- Check the parameters stored in the mappings table for any matches.&lt;br /&gt;
	local namespace = getNamespace(args) or &amp;#039;other&amp;#039; -- &amp;quot;other&amp;quot; avoids nil table keys&lt;br /&gt;
	local params = mappings[namespace] or {}&lt;br /&gt;
	local ret = fetchValue(args, params)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- If there were no matches, return parameters for other namespaces.&lt;br /&gt;
	-- This happens if there was no text specified for the namespace that&lt;br /&gt;
	-- was detected or if the demospace parameter is not a valid&lt;br /&gt;
	-- namespace. Note that the parameter for the detected namespace must be&lt;br /&gt;
	-- completely absent for this to happen, not merely blank.&lt;br /&gt;
	--]]&lt;br /&gt;
	if ret == nil then&lt;br /&gt;
		ret = fetchValue(args, argKeys.other)&lt;br /&gt;
	end&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.main(frame)&lt;br /&gt;
	mArguments = require(&amp;#039;Dev:Arguments&amp;#039;)&lt;br /&gt;
	local args = mArguments.getArgs(frame, {removeBlanks = false})&lt;br /&gt;
	local ret = p._main(args)&lt;br /&gt;
	return ret or &amp;#039;&amp;#039;&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function p.table(frame)&lt;br /&gt;
	--[[&lt;br /&gt;
	-- Create a wikitable of all subject namespace parameters, for&lt;br /&gt;
	-- documentation purposes. The talk parameter is optional, in case it&lt;br /&gt;
	-- needs to be excluded in the documentation.&lt;br /&gt;
	--]]&lt;br /&gt;
	&lt;br /&gt;
	-- Load modules and initialise variables.&lt;br /&gt;
	mTableTools = require(&amp;#039;Dev:TableTools&amp;#039;)&lt;br /&gt;
	local namespaces = mw.site.namespaces&lt;br /&gt;
	local cfg = data.cfg&lt;br /&gt;
	local useTalk = type(frame) == &amp;#039;table&amp;#039; &lt;br /&gt;
		and type(frame.args) == &amp;#039;table&amp;#039; &lt;br /&gt;
		and yesno(frame.args.talk) -- Whether to use the talk parameter.&lt;br /&gt;
	&lt;br /&gt;
	-- Get the header names.&lt;br /&gt;
	local function checkValue(value, default)&lt;br /&gt;
		if type(value) == &amp;#039;string&amp;#039; then&lt;br /&gt;
			return value&lt;br /&gt;
		else&lt;br /&gt;
			return default&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	local nsHeader = checkValue(cfg.wikitableNamespaceHeader, &amp;#039;Namespace&amp;#039;)&lt;br /&gt;
	local aliasesHeader = checkValue(cfg.wikitableAliasesHeader, &amp;#039;Aliases&amp;#039;)&lt;br /&gt;
&lt;br /&gt;
	-- Put the namespaces in order.&lt;br /&gt;
	local mappingsOrdered = {}&lt;br /&gt;
	for nsname, params in pairs(mappings) do&lt;br /&gt;
		if useTalk or nsname ~= &amp;#039;talk&amp;#039; then&lt;br /&gt;
			local nsid = namespaces[nsname].id&lt;br /&gt;
			-- Add 1, as the array must start with 1; nsid 0 would be lost otherwise.&lt;br /&gt;
			nsid = nsid + 1 &lt;br /&gt;
			mappingsOrdered[nsid] = params&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	mappingsOrdered = mTableTools.compressSparseArray(mappingsOrdered)&lt;br /&gt;
&lt;br /&gt;
	-- Build the table.&lt;br /&gt;
	local ret = &amp;#039;{| class=&amp;quot;wikitable&amp;quot;&amp;#039;&lt;br /&gt;
		.. &amp;#039;\n|-&amp;#039;&lt;br /&gt;
		.. &amp;#039;\n! &amp;#039; .. nsHeader&lt;br /&gt;
		.. &amp;#039;\n! &amp;#039; .. aliasesHeader&lt;br /&gt;
	for i, params in ipairs(mappingsOrdered) do&lt;br /&gt;
		for j, param in ipairs(params) do&lt;br /&gt;
			if j == 1 then&lt;br /&gt;
				ret = ret .. &amp;#039;\n|-&amp;#039;&lt;br /&gt;
					.. &amp;#039;\n| &amp;lt;code&amp;gt;&amp;#039; .. param .. &amp;#039;&amp;lt;/code&amp;gt;&amp;#039;&lt;br /&gt;
					.. &amp;#039;\n| &amp;#039;&lt;br /&gt;
			elseif j == 2 then&lt;br /&gt;
				ret = ret .. &amp;#039;&amp;lt;code&amp;gt;&amp;#039; .. param .. &amp;#039;&amp;lt;/code&amp;gt;&amp;#039;&lt;br /&gt;
			else&lt;br /&gt;
				ret = ret .. &amp;#039;, &amp;lt;code&amp;gt;&amp;#039; .. param .. &amp;#039;&amp;lt;/code&amp;gt;&amp;#039;&lt;br /&gt;
			end&lt;br /&gt;
		end&lt;br /&gt;
	end&lt;br /&gt;
	ret = ret .. &amp;#039;\n|-&amp;#039;&lt;br /&gt;
		.. &amp;#039;\n|}&amp;#039;&lt;br /&gt;
	return ret&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Admin coral island</name></author>
	</entry>
</feed>