mm_machine 1.5.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +4 -1
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -61,7 +61,7 @@ class Item {
|
|
|
61
61
|
*/
|
|
62
62
|
"sort": 10,
|
|
63
63
|
/**
|
|
64
|
-
* 状态, 1
|
|
64
|
+
* 状态, 0表示未启用, 1表示启用
|
|
65
65
|
*/
|
|
66
66
|
"state": 1
|
|
67
67
|
};
|
|
@@ -124,6 +124,9 @@ Item.prototype.loadObj = function(config) {
|
|
|
124
124
|
if (f) {
|
|
125
125
|
var file = f.fullname(this.dir);
|
|
126
126
|
if (file.hasFile()) {
|
|
127
|
+
if(!config.state){
|
|
128
|
+
return;
|
|
129
|
+
}
|
|
127
130
|
this.remove_module(file);
|
|
128
131
|
var cs = require(file);
|
|
129
132
|
if (cs) {
|