-
-
Save ohadlevy/3898483 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
diff --git a/app/models/lookup_key.rb b/app/models/lookup_key.rb | |
index 256f07d..0a27c99 100644 | |
--- a/app/models/lookup_key.rb | |
+++ b/app/models/lookup_key.rb | |
@@ -150,8 +150,8 @@ class LookupKey < ActiveRecord::Base | |
begin | |
self.default_value = cast_validate_value self.default_value | |
true | |
- rescue | |
- errors.add(:default_value, "is invalid") | |
+ rescue => e | |
+ errors.add(:default_value, "is invalid for #{to_s}: #{e}") | |
false | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment