Method: Sequel::Postgres::JSONDatabaseMethods.jsonb_wrapper

Defined in:
lib/sequel/extensions/pg_json.rb

.jsonb_wrapper(value) ⇒ Object

Return the wrapper class for the jsonb type if value is Hash or Array.

[View source]

260
261
262
263
264
265
266
267
# File 'lib/sequel/extensions/pg_json.rb', line 260

def self.jsonb_wrapper(value)
  case value
  when ::Hash
    JSONBHash
  when ::Array
    JSONBArray
  end
end