Allow an __appName__ parameter in translations

This commit is contained in:
James Allen 2015-03-09 12:14:30 +00:00
parent b41cdb424b
commit d376acdaa9
2 changed files with 5 additions and 1 deletions

View file

@ -56,7 +56,9 @@ module.exports = (app)->
next()
app.use (req, res, next)->
res.locals.translate = req.i18n.translate
res.locals.translate = (key, vars = {}) ->
vars.appName = Settings.appName
req.i18n.translate(key, vars)
res.locals.currentUrl = req.originalUrl
next()

View file

@ -262,6 +262,8 @@ module.exports =
# user: ""
# password: ""
# projectId: ""
appName: "ShareLaTeX (Community Edition)"
nav:
title: "ShareLaTeX Community Edition"