Commit d0a06bf2 authored by Samuel E. Giddins's avatar Samuel E. Giddins

[Command] Use a case statement in Pod::Command#report_error

Addresses https://github.com/CocoaPods/CocoaPods/commit/0c80af37f1fec0009ad63277309afa47ad22595f#commitcomment-7718723.
parent 33b60b6d
......@@ -48,11 +48,12 @@ module Pod
end
def self.report_error(exception)
if exception.is_a?(Interrupt)
case exception
when Interrupt
puts '[!] Cancelled'.red
Config.instance.verbose? ? raise : exit(1)
elsif exception.is_a?(SystemExit)
raise exception
when SystemExit
raise
else
if ENV['COCOA_PODS_ENV'] != 'development'
puts UI::ErrorReport.report(exception)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment