Skip to content

Node.js based forum software built for the modern web

Fix web installer benchpress issue

Peter Jaszkowiak2ca1475eee8f
diff --git a/install/web.js b/install/web.js
index 58767b776a..758e2f3c57 100644
--- a/install/web.js
+++ b/install/web.js
@@ -37,7 +37,16 @@ web.install = function (port) {
winston.info('Launching web installer on port', port);
app.use(express.static('public', {}));
- app.engine('tpl', Benchpress.__express);
+ app.engine('tpl', function (filepath, options, callback) {
+ async.waterfall([
+ function (next) {
+ fs.readFile(filepath, 'utf-8', next);
+ },
+ function (buffer, next) {
+ Benchpress.compileParse(buffer.toString(), options, next);
+ }
+ ], callback);
+ });
app.set('view engine', 'tpl');
app.set('views', path.join(__dirname, '../src/views'));
app.use(bodyParser.urlencoded({