Merge pull request #449 from sharelatex/ho-trust-blog-urls

don't add /blog to the start of blog urls in annoucements
This commit is contained in:
James Allen 2017-03-09 13:28:36 +00:00 committed by GitHub
commit 604aa7859e

View file

@ -10,7 +10,7 @@ module.exports = BlogHandler =
opts =
url:blogUrl
json:true
timeout:500
timeout:1000
request.get opts, (err, res, announcements)->
if err?
return callback err
@ -18,7 +18,6 @@ module.exports = BlogHandler =
return callback("blog announcement returned non 200")
logger.log announcementsLength: announcements?.length, "announcements returned"
announcements = _.map announcements, (announcement)->
announcement.url = "/blog#{announcement.url}"
announcement.date = new Date(announcement.date)
return announcement
callback(err, announcements)