mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
don't add /blog to the start of blog urls in annoucements
also up timeout
This commit is contained in:
parent
111c6ab281
commit
63b84d3724
1 changed files with 1 additions and 2 deletions
|
@ -10,7 +10,7 @@ module.exports = BlogHandler =
|
||||||
opts =
|
opts =
|
||||||
url:blogUrl
|
url:blogUrl
|
||||||
json:true
|
json:true
|
||||||
timeout:500
|
timeout:1000
|
||||||
request.get opts, (err, res, announcements)->
|
request.get opts, (err, res, announcements)->
|
||||||
if err?
|
if err?
|
||||||
return callback err
|
return callback err
|
||||||
|
@ -18,7 +18,6 @@ module.exports = BlogHandler =
|
||||||
return callback("blog announcement returned non 200")
|
return callback("blog announcement returned non 200")
|
||||||
logger.log announcementsLength: announcements?.length, "announcements returned"
|
logger.log announcementsLength: announcements?.length, "announcements returned"
|
||||||
announcements = _.map announcements, (announcement)->
|
announcements = _.map announcements, (announcement)->
|
||||||
announcement.url = "/blog#{announcement.url}"
|
|
||||||
announcement.date = new Date(announcement.date)
|
announcement.date = new Date(announcement.date)
|
||||||
return announcement
|
return announcement
|
||||||
callback(err, announcements)
|
callback(err, announcements)
|
||||||
|
|
Loading…
Reference in a new issue