mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-03-04 19:41:16 +01:00
ESlint comma-dangle
This commit is contained in:
@@ -7,7 +7,7 @@ module.exports = function (Plugins) {
|
||||
Plugins.deprecatedHooks = {
|
||||
'filter:user.custom_fields': null, // remove in v1.1.0
|
||||
'filter:post.save': 'filter:post.create',
|
||||
'filter:user.profileLinks': 'filter:user.profileMenu'
|
||||
'filter:user.profileLinks': 'filter:user.profileMenu',
|
||||
};
|
||||
/*
|
||||
`data` is an object consisting of (* is required):
|
||||
@@ -36,7 +36,7 @@ module.exports = function (Plugins) {
|
||||
(Plugins.deprecatedHooks[data.hook] ?
|
||||
'please use `' + Plugins.deprecatedHooks[data.hook] + '` instead.' :
|
||||
'there is no alternative.'
|
||||
)
|
||||
),
|
||||
);
|
||||
} else {
|
||||
// handle hook's startsWith, i.e. action:homepage.get
|
||||
|
||||
@@ -52,7 +52,7 @@ module.exports = function (Plugins) {
|
||||
meta.reloadRequired = true;
|
||||
Plugins.fireHook(isActive ? 'action:plugin.deactivate' : 'action:plugin.activate', id);
|
||||
next();
|
||||
}
|
||||
},
|
||||
], function (err) {
|
||||
if (err) {
|
||||
winston.warn('[plugins] Could not toggle active state on plugin \'' + id + '\'');
|
||||
@@ -97,7 +97,7 @@ module.exports = function (Plugins) {
|
||||
function (pluginData, next) {
|
||||
Plugins.fireHook('action:plugin.' + type, id);
|
||||
next(null, pluginData);
|
||||
}
|
||||
},
|
||||
], callback);
|
||||
}
|
||||
|
||||
@@ -126,7 +126,7 @@ module.exports = function (Plugins) {
|
||||
function (isActive, next) {
|
||||
meta.reloadRequired = isActive;
|
||||
next(null, isActive);
|
||||
}
|
||||
},
|
||||
], callback);
|
||||
}
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@ module.exports = function (Plugins) {
|
||||
async.apply(mapStaticDirectories, pluginData, pluginData.path),
|
||||
], next);
|
||||
}, next);
|
||||
}
|
||||
},
|
||||
], callback);
|
||||
};
|
||||
|
||||
@@ -283,7 +283,7 @@ module.exports = function (Plugins) {
|
||||
},
|
||||
plugin: function (next) {
|
||||
fs.readFile(path.join(pluginPath, 'plugin.json'), next);
|
||||
}
|
||||
},
|
||||
}, function (err, results) {
|
||||
if (err) {
|
||||
return callback(err);
|
||||
|
||||
Reference in New Issue
Block a user