Module:Documentation: Difference between revisions

Fix Template:Documentation header not adding content/categories to /doc pages
m Add debug logs
Line 16: Line 16:
end
end
mw.logObject(pageType, "Module:Documentation: pageType")
return pageType
return pageType
end
end
Line 60: Line 61:
local args = require( 'Module:ProcessArgs' ).merge( true )
local args = require( 'Module:ProcessArgs' ).merge( true )
local badDoc = args.baddoc
local badDoc = args.baddoc
if f:callParserFunction( '#dplvar', '$doc noheader' ) == '1' then
mw.logObject(badDoc, "Module:Documentation: badDoc")
local dplvar = f:callParserFunction( '#dplvar', '$doc noheader' )
mw.logObject(dplvar, "Module:Documentation: dplvar")
if dplvar == '1' then
if badDoc then
if badDoc then
f:callParserFunction( '#dplvar:set', '$doc bad', '1' )
f:callParserFunction( '#dplvar:set', '$doc bad', '1' )
Line 95: Line 99:
end
end
return tostring(body)
mw.logObject(body, "Module:Documentation: body")
return tostring(body) .. "<hr>"
end
end