Skip to content

Conversation

@gdiggs
Copy link
Contributor

@gdiggs gdiggs commented Jul 6, 2016

The previous solution caused an error when no files were analyzed, so
return a special string if anything errors.

@codeclimate/review

Runner.php Outdated
} catch (Exception $e) {
error_log("Exception: " . $e->getMessage() . " in " . $e->getFile() . "\n" . $e->getTraceAsString());
return false;
return "cc_exception_thrown";
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(Assuming this is possible) WDYT about returning $e then checking (PHP's version of) is_a?(Exception)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call - updated!

The previous solution caused an error when no files were analyzed, so check the type of the exception itself
@gdiggs
Copy link
Contributor Author

gdiggs commented Jul 6, 2016

@codeclimate/review ready for another look!

@gdiggs gdiggs merged commit 835b453 into master Jul 6, 2016
@gdiggs gdiggs deleted the gd-string branch July 6, 2016 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants