mirror of
https://github.com/zhigang1992/deployd.git
synced 2026-05-24 05:47:45 +08:00
removed legacy plugin path unshift
This commit is contained in:
@@ -11,14 +11,11 @@ var config = require('./config').load()
|
||||
, path
|
||||
;
|
||||
|
||||
// expose current directory to plugins
|
||||
require.paths.unshift('.');
|
||||
|
||||
// load plugins
|
||||
plugins.forEach(function(fd) {
|
||||
path = __dirname + '/plugins/' + fd;
|
||||
if(fs.statSync(path).isDirectory()) {
|
||||
lib[fd] = require(path);
|
||||
lib[fd] = require(path);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ module.exports = Model.spawn({
|
||||
refresh: function(changes) {
|
||||
if(!changes.errors) {
|
||||
if(changes.plugin === 'models') models.refresh();
|
||||
else if(changes.collection) Model.refreshSettings(json.collection);
|
||||
else if(changes.collection) Model.refreshSettings(changes.collection);
|
||||
}
|
||||
|
||||
Model.refresh.apply(this, arguments);
|
||||
|
||||
Reference in New Issue
Block a user