|
|
@ -27,8 +27,9 @@
|
|
|
|
async = require('async'),
|
|
|
|
async = require('async'),
|
|
|
|
semver = require('semver'),
|
|
|
|
semver = require('semver'),
|
|
|
|
winston = require('winston'),
|
|
|
|
winston = require('winston'),
|
|
|
|
pkg = require('./package.json'),
|
|
|
|
|
|
|
|
path = require('path'),
|
|
|
|
path = require('path'),
|
|
|
|
|
|
|
|
pkg = require('./package.json'),
|
|
|
|
|
|
|
|
utils = require('./public/src/utils.js'),
|
|
|
|
meta;
|
|
|
|
meta;
|
|
|
|
|
|
|
|
|
|
|
|
// Runtime environment
|
|
|
|
// Runtime environment
|
|
|
@ -108,16 +109,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
var customTemplates = meta.config['theme:templates'] ? path.join(__dirname, 'node_modules', meta.config['theme:id'], meta.config['theme:templates']) : false;
|
|
|
|
var customTemplates = meta.config['theme:templates'] ? path.join(__dirname, 'node_modules', meta.config['theme:id'], meta.config['theme:templates']) : false;
|
|
|
|
|
|
|
|
|
|
|
|
// todo: replace below with read directory code, derp.
|
|
|
|
|
|
|
|
templates.init([
|
|
|
|
utils.walk(path.join(__dirname, 'public/templates'), function (err, tplsToLoad) {
|
|
|
|
'header', 'footer', 'logout', 'outgoing', 'admin/header', 'admin/footer', 'admin/index',
|
|
|
|
templates.init(tplsToLoad, customTemplates);
|
|
|
|
'emails/reset', 'emails/reset_plaintext', 'emails/email_confirm', 'emails/email_confirm_plaintext',
|
|
|
|
});
|
|
|
|
'emails/header', 'emails/footer',
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
'noscript/header', 'noscript/home', 'noscript/category', 'noscript/topic'
|
|
|
|
|
|
|
|
], customTemplates);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
plugins.ready(function() {
|
|
|
|
plugins.ready(function() {
|
|
|
|
templates.ready(webserver.init);
|
|
|
|
templates.ready(webserver.init);
|
|
|
|
});
|
|
|
|
});
|
|
|
|