mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-03 20:45:58 +01:00
updating code to not use a hardcoded version number, but rather read the #
from package.json
This commit is contained in:
@@ -8,6 +8,7 @@ var express = require('express'),
|
||||
redisServer = redis.createClient(global.config.redis.port, global.config.redis.host),
|
||||
marked = require('marked'),
|
||||
utils = require('../public/src/utils.js'),
|
||||
pkg = require('../package.json'),
|
||||
fs = require('fs'),
|
||||
|
||||
user = require('./user.js'),
|
||||
@@ -304,7 +305,7 @@ var express = require('express'),
|
||||
|
||||
async.each(data.categories, iterator, function(err) {
|
||||
data.motd_class = (config.show_motd === '1' || config.show_motd === undefined) ? '' : 'none';
|
||||
data.motd = marked(config.motd || "# NodeBB v" + global.ver + "\nWelcome to NodeBB, the discussion platform of the future.\n\n<a target=\"_blank\" href=\"http://www.nodebb.org\" class=\"btn btn-large\"><i class=\"icon-comment\"></i> Get NodeBB</a> <a target=\"_blank\" href=\"https://github.com/designcreateplay/NodeBB\" class=\"btn btn-large\"><i class=\"icon-github-alt\"></i> Fork us on Github</a> <a target=\"_blank\" href=\"https://twitter.com/dcplabs\" class=\"btn btn-large\"><i class=\"icon-twitter\"></i> @dcplabs</a>");
|
||||
data.motd = marked(config.motd || "# NodeBB v" + pkg.version + "\nWelcome to NodeBB, the discussion platform of the future.\n\n<a target=\"_blank\" href=\"http://www.nodebb.org\" class=\"btn btn-large\"><i class=\"icon-comment\"></i> Get NodeBB</a> <a target=\"_blank\" href=\"https://github.com/designcreateplay/NodeBB\" class=\"btn btn-large\"><i class=\"icon-github-alt\"></i> Fork us on Github</a> <a target=\"_blank\" href=\"https://twitter.com/dcplabs\" class=\"btn btn-large\"><i class=\"icon-twitter\"></i> @dcplabs</a>");
|
||||
res.json(data);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user