JSON.dump and JSON.load shouldn’t be used with untrusted input, so we create this wrapper class which calls JSON.generate and JSON.parse instead.
Public Class methods
dump(data)
[show source]
# File lib/shrine/plugins/column.rb 92 def self.dump(data) 93 JSON.generate(data) 94 end
load(data)
[show source]
# File lib/shrine/plugins/column.rb 96 def self.load(data) 97 JSON.parse(data) 98 end