Created
December 6, 2021 13:32
-
-
Save gregblake/c656d2755d82e1d216f7b11ced6e58c5 to your computer and use it in GitHub Desktop.
Error Catching
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def new_query(params, current_user) | |
begin | |
# existing code from `new_query` | |
rescue ActiveRecord::StatementInvalid => e | |
binding.pry | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment