diff options
author | namusyaka <namusyaka@gmail.com> | 2016-02-16 11:35:52 +0900 |
---|---|---|
committer | namusyaka <namusyaka@gmail.com> | 2016-04-09 23:49:43 +0900 |
commit | 91386c1b355947955b05ee3846e4aedd4eec0eb1 (patch) | |
tree | c09bcb439aea67fd1cefd88f91da0ad1ad3e8593 /activesupport/lib | |
parent | e88d63e6f7a7e9a73484ea30859bf3b75a4b7188 (diff) | |
download | rails-91386c1b355947955b05ee3846e4aedd4eec0eb1.tar.gz rails-91386c1b355947955b05ee3846e4aedd4eec0eb1.tar.bz2 rails-91386c1b355947955b05ee3846e4aedd4eec0eb1.zip |
Fix behavior of JSON encoding for Exception
Diffstat (limited to 'activesupport/lib')
-rw-r--r-- | activesupport/lib/active_support/core_ext/object/json.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/core_ext/object/json.rb b/activesupport/lib/active_support/core_ext/object/json.rb index 0db787010c..d49b2fbe54 100644 --- a/activesupport/lib/active_support/core_ext/object/json.rb +++ b/activesupport/lib/active_support/core_ext/object/json.rb @@ -197,3 +197,9 @@ class Process::Status #:nodoc: { :exitstatus => exitstatus, :pid => pid } end end + +class Exception + def as_json(options = nil) + to_s + end +end |