diff options
Diffstat (limited to 'activesupport/lib/active_support/json/variable.rb')
-rw-r--r-- | activesupport/lib/active_support/json/variable.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/json/variable.rb b/activesupport/lib/active_support/json/variable.rb new file mode 100644 index 0000000000..325ac9b7a6 --- /dev/null +++ b/activesupport/lib/active_support/json/variable.rb @@ -0,0 +1,10 @@ +module ActiveSupport + module JSON + # A string that returns itself as as its JSON-encoded form. + class Variable < String + def to_json + self + end + end + end +end |