class Glueby::Contract::AR::Timestamp

Public Class Methods

new(attributes = nil) click to toggle source

@param [Hash] attributes attributes which consist of:

  • wallet_id

  • content

  • prefix(optional)

Calls superclass method
# File lib/glueby/contract/active_record/timestamp.rb, line 12
def initialize(attributes = nil)
  @content_hash = Tapyrus.sha256(attributes[:content]).bth
  super(wallet_id: attributes[:wallet_id], content_hash: @content_hash,
        prefix: attributes[:prefix] ? attributes[:prefix] : '', status: :init)
end