From dd619f44dde651e474c3447f760734681d149da9 Mon Sep 17 00:00:00 2001 From: James Allen Date: Fri, 17 Nov 2017 11:55:49 +0000 Subject: [PATCH] Add in setting to control whether the site has a homepage --- .../web/app/coffee/Features/StaticPages/HomeController.coffee | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/web/app/coffee/Features/StaticPages/HomeController.coffee b/services/web/app/coffee/Features/StaticPages/HomeController.coffee index c1a8c46323..f2971393c4 100755 --- a/services/web/app/coffee/Features/StaticPages/HomeController.coffee +++ b/services/web/app/coffee/Features/StaticPages/HomeController.coffee @@ -1,4 +1,5 @@ logger = require('logger-sharelatex') +Settings = require('settings-sharelatex') _ = require('underscore') Path = require "path" @@ -20,12 +21,11 @@ module.exports = HomeController = HomeController.home(req, res) home: (req, res)-> - if homepageExists + if Settings.showHomepage and homepageExists res.render 'external/home' else res.redirect "/login" - externalPage: (page, title) -> return (req, res, next = (error) ->) -> path = Path.resolve(__dirname + "/../../../views/external/#{page}.pug")