From 45a3b6afd1974012dcff8a4819a0cc3697057343 Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 9 Apr 2024 11:55:11 -0700 Subject: [PATCH] cc: adjust config --- .codeclimate.yml | 4 ++-- index.js | 19 +++++++------------ 2 files changed, 9 insertions(+), 14 deletions(-) diff --git a/.codeclimate.yml b/.codeclimate.yml index 0e0a85a..8b9c8d1 100644 --- a/.codeclimate.yml +++ b/.codeclimate.yml @@ -18,7 +18,7 @@ checks: threshold: 500 method-lines: config: - threshold: 45 + threshold: 50 method-complexity: config: - threshold: 10 + threshold: 11 diff --git a/index.js b/index.js index b080511..09b33ea 100644 --- a/index.js +++ b/index.js @@ -10,18 +10,13 @@ exports.register = function () { this.init_lists() this.load_access_ini() // update with *.ini settings - let p - for (p in this.cfg.white) { - this.load_file('white', p) - } - for (p in this.cfg.black) { - this.load_file('black', p) - } - for (p in this.cfg.re.white) { - this.load_re_file('white', p) - } - for (p in this.cfg.re.black) { - this.load_re_file('black', p) + for (const c of 'black', 'white') { + for (p in this.cfg[c]) { + this.load_file(c, p) + } + for (p in this.cfg.re[c]) { + this.load_re_file(c, p) + } } if (this.cfg.check.conn) {