Module:Message box: Difference between revisions

refer to discord server since nobody really uses talk pages here, i have no idea how modules work so hopefully this doesn't break everything
imported>YungCyraxxAlt
No edit summary
imported>Larsonologist
(refer to discord server since nobody really uses talk pages here, i have no idea how modules work so hopefully this doesn't break everything)
 
(4 intermediate revisions by 2 users not shown)
Line 114: Line 114:
obj.categories = {}
obj.categories = {}
obj.classes = {}
obj.classes = {}
-- For lazy loading of [[Module:Category handler]].
obj.hasCategories = false
obj.hasCategories = false


Line 275: Line 274:
                     else
                     else
                         talkText = string.format(
                         talkText = string.format(
                             '%s the [[%s#%s|talk page]].',
                             '%s the [[%s#%s|talk page]] or the Discord server.',
                             talkText,
                             talkText,
                             talkTitle.prefixedText,
                             talkTitle.prefixedText,
Line 454: Line 453:
end
end
-- Convert category tables to strings and pass them through
-- Convert category tables to strings and pass them through
-- [[Module:Category handler]].
return require('Module:Category handler')._main{
main = table.concat(self.categories[0] or {}),
template = table.concat(self.categories[10] or {}),
all = table.concat(self.categories.all or {}),
nocat = self.args.nocat,
page = self.args.page
}
end
end