Module: Rubino::API::Operations::Memory::Serializer

Defined in:
lib/rubino/api/operations/memory/index_operation.rb

Overview

Shared serializer for the memory surface. Backends differ slightly in the rows they return (the sqlite backend omits :updated_at), so every field is read defensively and absent ones serialize to null.

Class Method Summary collapse

Class Method Details

.call(row) ⇒ Object



67
68
69
70
71
72
73
74
75
# File 'lib/rubino/api/operations/memory/index_operation.rb', line 67

def call(row)
  {
    id: row[:id],
    kind: row[:kind],
    content: row[:content],
    created_at: row[:created_at],
    updated_at: row[:updated_at]
  }
end