mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-06-06 04:37:12 +02:00
* Rewrite of menu.json handling. More flexability
* Wildcards in menu.json * Basic menu.json submit filtering working
This commit is contained in:
parent
1ae571ee44
commit
ae71aa9feb
5 changed files with 124 additions and 87 deletions
|
@ -6,6 +6,7 @@ var paths = require('path');
|
|||
|
||||
var conf = require('./config.js');
|
||||
var miscUtil = require('./misc_util.js');
|
||||
var _ = require('lodash');
|
||||
|
||||
// exports
|
||||
exports.loadModule = loadModule;
|
||||
|
@ -36,7 +37,7 @@ function loadModule(name, category, cb) {
|
|||
return;
|
||||
}
|
||||
|
||||
if(!mod.getModule || typeof mod.getModule !== 'function') {
|
||||
if(!_.isFunction(mod.getModule)) {
|
||||
cb(new Error('Invalid or missing missing \'getModule\' method'));
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue