Module:Header: Difference between revisions

Content deleted Content added
add code for getting year from WD; fix other year bugs; make section a div
add tracking category for defaultsort application
Line 329:
defsortKey = table.concat(sorted_title_table, '/')
if defsortKey == title then
defsortKey = nil
end
end
-- if a suitable key is found or constructed, apply it
if defsortKey and title ~== title then
return '[[Category:' .. 'Headers with DefaultSort equal to page title' .. ']]'
elseif defsortKey then
return mw.getCurrentFrame():preprocess{text = '{{DEFAULTSORT:' .. defsortKey .. '}}'} .. '[[Category:' .. 'Headers applying DefaultSort key' .. ']]'
end