Skip to content
This repository has been archived by the owner on Feb 12, 2022. It is now read-only.

Commit

Permalink
Move RequestTimeout rescue before RequestFailed
Browse files Browse the repository at this point in the history
Since RequestTimeout is a subclass of RequestFailed, we'd never see the
specialized error message printed by rescuing a RequestTimeout.
  • Loading branch information
brandur committed Apr 17, 2012
1 parent faf290c commit 67f8441
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/heroku/command.rb
Expand Up @@ -164,10 +164,10 @@ def self.run(cmd, arguments=[])
arguments << '--confirm' << app
retry
end
rescue RestClient::RequestFailed => e
error extract_error(e.http_body)
rescue RestClient::RequestTimeout
error "API request timed out. Please try again, or contact support@heroku.com if this issue persists."
rescue RestClient::RequestFailed => e
error extract_error(e.http_body)
rescue CommandFailed => e
error e.message
rescue OptionParser::ParseError => ex
Expand Down

0 comments on commit 67f8441

Please sign in to comment.