Files
loop-etl-rocketchat/lib/modules/team.js
2026-05-13 20:03:28 +03:00

30 lines
578 B
JavaScript

const Factory = require('../factory')
//
// Initialize the child logger for
// the module
//
const log = require('../log').child({
module: 'team'
})
module.exports = function(context) {
log.info(`writing team '${context.config.define.team.name}'`)
//
// Store the team object for use
// by other modules
//
context.values.team = context.config.define.team
//
// Write the team object to the
// output
//
context.output.write(Factory.team(
context.config.define.team
))
//
// Return a resolved promise
//
return Promise.resolve(context)
}