lint: Fix some ESLint errors in pluginfw
parent
a45e85a730
commit
a8479e4a0e
|
@ -21,15 +21,15 @@ const onAllTasksFinished = () => {
|
|||
|
||||
let tasks = 0;
|
||||
|
||||
function wrapTaskCb(cb) {
|
||||
const wrapTaskCb = (cb) => {
|
||||
tasks++;
|
||||
|
||||
return function (...args) {
|
||||
cb && cb.apply(this, args);
|
||||
return (...args) => {
|
||||
cb && cb(...args);
|
||||
tasks--;
|
||||
if (tasks === 0) onAllTasksFinished();
|
||||
};
|
||||
}
|
||||
};
|
||||
|
||||
exports.uninstall = async (pluginName, cb = null) => {
|
||||
cb = wrapTaskCb(cb);
|
||||
|
|
|
@ -5,9 +5,6 @@ const hooks = require('./hooks');
|
|||
const path = require('path');
|
||||
const runNpm = require('../../../node/utils/run_npm');
|
||||
const tsort = require('./tsort');
|
||||
const util = require('util');
|
||||
const settings = require('../../../node/utils/Settings');
|
||||
|
||||
const pluginUtils = require('./shared');
|
||||
const defs = require('./plugin_defs');
|
||||
|
||||
|
|
Loading…
Reference in New Issue