Make error messages print on error
This commit is contained in:
parent
b02e8402b3
commit
c66b0f9aff
|
@ -52,10 +52,10 @@ module GitHubChangelogGenerator
|
|||
begin
|
||||
value = yield
|
||||
rescue Github::Error::Unauthorized => e
|
||||
Helper.log.error e.body.red
|
||||
Helper.log.warn e.error_messages.map { |m| m[:message] }.join(", ").red
|
||||
abort "Error: wrong GitHub token"
|
||||
rescue Github::Error::Forbidden => e
|
||||
Helper.log.warn e.body.red
|
||||
Helper.log.warn e.error_messages.map { |m| m[:message] }.join(", ").red
|
||||
Helper.log.warn GH_RATE_LIMIT_EXCEEDED_MSG.yellow
|
||||
end
|
||||
value
|
||||
|
|
Loading…
Reference in New Issue
Block a user