mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
add redirect to /i/university for ab test
This commit is contained in:
parent
9238462fe4
commit
26a4076c22
1 changed files with 8 additions and 3 deletions
|
@ -8,7 +8,7 @@ sanitize = require('sanitizer')
|
|||
Settings = require("settings-sharelatex")
|
||||
contentful = require('contentful')
|
||||
marked = require("marked")
|
||||
|
||||
sixpack = require("../../infrastructure/Sixpack")
|
||||
|
||||
|
||||
|
||||
|
@ -36,8 +36,13 @@ module.exports = UniversityController =
|
|||
|
||||
|
||||
getIndexPage: (req, res)->
|
||||
req.url = "/university/index.html"
|
||||
UniversityController.getPage req, res
|
||||
client = sixpack.client(req?.session?.user?._id?.toString() || req.ip)
|
||||
client.participate 'instapage-pages', ['default', 'instapage'], (err, response)->
|
||||
if response?.alternative?.name == "instapage"
|
||||
return res.redirect("/i/university")
|
||||
else
|
||||
req.url = "/university/index.html"
|
||||
UniversityController.getPage req, res
|
||||
|
||||
_directProxy: (originUrl, res)->
|
||||
upstream = request.get(originUrl)
|
||||
|
|
Loading…
Reference in a new issue