Added LDoc comments for new files, ready to merge pt. 2

This commit is contained in:
SkylarHew
2022-01-23 18:21:23 -07:00
parent e72911c67c
commit 79b548f9a0
24 changed files with 118 additions and 94 deletions

View File

@ -1,11 +1,6 @@
--- defer_consent
--- Defer consent
-- @module defer_consent
--- (Required): data table containing name and description of the module
-- @field name "Human-readable name (parens OK, no brackets)"
-- @field slug "Same as module class name"
-- @field desc "Description of the module"
-- @field hide "Whether this is a hidden utility module"
local defer_consent = {
name = "Defer consent",
slug = "defer_consent",
@ -13,13 +8,10 @@ local defer_consent = {
hide = true;
}
--- (Required) Data for module
-- Variables that module uses during the course of a process
-- Can be blank
defer_consent.data = {
}
--- (Required): config for module
--- Config for module
-- @field defer_org Name or ID of target org
-- @field votes_required Threshold passed on to `consent`
-- @field prompt String passed on to `consent`
@ -29,9 +21,9 @@ defer_consent.config = {
prompt = "Do you consent?"
}
--- (Required): initiate function
-- @param result (optional) Callback if this module is embedded in other modules
-- @function initiate
--- Initiate function
-- @param result Callback if this module is embedded in other modules
-- @function defer_consent:initiate
function defer_consent:initiate(result)
local defer_org = modpol.orgs.get_org(self.config.defer_org)
if not defer_org then