discourse/app/serializers/group_user_serializer.rb
Dan Ungureanu 2e085915cc
FIX: include_ serializer methods must end with ? (#14407)
Otherwise, they are simply dead code and the attribute is visible by
default. These bugs did not expose any sensitive information.
2021-09-22 16:01:25 +03:00

18 lines
327 B
Ruby

# frozen_string_literal: true
class GroupUserSerializer < BasicUserSerializer
include UserPrimaryGroupMixin
attributes :name,
:title,
:last_posted_at,
:last_seen_at,
:added_at,
:timezone
def include_added_at?
object.respond_to? :added_at
end
end