Class: Alchemy::EssencePictureSerializer

Inherits:
ActiveModel::Serializer
  • Object
show all
Defined in:
app/serializers/alchemy/essence_picture_serializer.rb

Instance Method Summary collapse

Instance Method Details



17
18
19
20
21
22
23
24
25
# File 'app/serializers/alchemy/essence_picture_serializer.rb', line 17

def link
  return if object.link.blank?
  {
    url: object.link,
    css_class: object.link_class_name,
    title: object.link_title,
    target: object.link_target
  }
end