Gab-Social/app/serializers/rest/chat_messenger_blocked_serializer.rb
mgabdev 7ec426e3d8 Progress on DMs
Progress on DMs
2020-12-19 01:33:33 -05:00

19 lines
355 B
Ruby

# frozen_string_literal: true
class REST::ChatMessengerBlockedSerializer < ActiveModel::Serializer
attributes :target_id, :chat_blocking, :chat_blocked_by
def target_id
object.id.to_s
end
def chat_blocking
instance_options[:chat_blocking] || false
end
def chat_blocked_by
instance_options[:chat_blocked_by] || false
end
end