Skip to content

Commit d627811

Browse files
chore: fix codacy error
1 parent fc7f945 commit d627811

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

plugins/pluginManager.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ const async: any = require('async');
191191
const _: any = require('underscore');
192192
const crypto: typeof import('crypto') = require('crypto');
193193
const BluebirdPromise: any = require('bluebird');
194-
const debug: any = require('debug')('countly:pluginManager');
194+
const debug: any = require('debug');
195195
const log: LogModule = require('../api/utils/log.js');
196196
const logDbRead: Logger = log('db:read');
197197
const logDbWrite: Logger = log('db:write');
@@ -200,6 +200,7 @@ const exec: typeof cp.exec = cp.exec;
200200
const spawn: typeof cp.spawn = cp.spawn;
201201
const configextender: ConfigExtenderFn = require('../api/configextender');
202202

203+
const d = debug('countly:pluginManager');
203204
// ============================================================
204205
// INTERNAL INTERFACES (used within this module only)
205206
// ============================================================
@@ -439,7 +440,7 @@ class PluginManager {
439440
catch (ex: any) {
440441
const errorLine = (ex.message || '').split('\n')[0];
441442
console.log('Skipping plugin ' + pluginNames[i] + ': ' + errorLine);
442-
debug('Plugin %s load error:\n%s', pluginNames[i], ex.stack);
443+
d('Plugin %s load error:\n%s', pluginNames[i], ex.stack);
443444
}
444445
}
445446
}
@@ -1275,7 +1276,7 @@ class PluginManager {
12751276
catch (ex: any) {
12761277
const errorLine = (ex.message || '').split('\n')[0];
12771278
console.log('Skipping plugin ' + pluginNames[i] + ': ' + errorLine);
1278-
debug('Plugin %s load error:\n%s', pluginNames[i], ex.stack);
1279+
d('Plugin %s load error:\n%s', pluginNames[i], ex.stack);
12791280
}
12801281
}
12811282
}

0 commit comments

Comments
 (0)