Baphomet is the dedicated bot for nulloctet matrix
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
502 B

  1. let { logger } = require('./logging');
  2. var configPath = null;
  3. var config = null;
  4. function sanitizeConfig(config) {
  5. let clonedConfig = { ...config };
  6. clonedConfig.accessToken = "******"
  7. return clonedConfig;
  8. }
  9. function getConfig(configFile) {
  10. if (config === null) {
  11. configPath = configFile;
  12. config = require(configFile);
  13. logger.info("Loaded config:");
  14. logger.debug("%o", sanitizeConfig(config));
  15. }
  16. return config;
  17. }
  18. exports.getConfig = getConfig