Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Two fixes to the new HEROKU_URL option #273

Merged
merged 3 commits into from Apr 15, 2012
View
@@ -193,12 +193,12 @@ class Robot
@connect.listen process.env.PORT || 8080
- hostname = process.env.HEROKU_URL
- hostname += '/' unless /\/$/.test hostname
+ herokuUrl = process.env.HEROKU_URL
- if hostname
+ if herokuUrl
+ herokuUrl += '/' unless /\/$/.test herokuUrl
setInterval =>
- HttpClient.create("#{hostname}/hubot/ping")
+ HttpClient.create("#{herokuUrl}hubot/ping")
.post() (err, res, body) =>
@logger.info "keep alive ping!"
, 1200000