class Battlerite::Asset

Attributes

blob[R]
created[R]
description[R]
name[R]

Public Class Methods

munch(asset, relationships, blob) click to toggle source
# File lib/battlerite/models/asset.rb, line 6
def self.munch asset, relationships, blob
  a = self.new(
    id: asset["id"],
    created: Time.parse(asset["attributes"]["createdAt"]),
    description: asset["attributes"]["description"],
    name: asset["attributes"]["name"],
    relationships: relationships,
    blob: blob,
  )
end