class UserSerializer < ActiveModel::Serializer
attributes :id, :email, :can_update, :can_delete
def can_update
scope.can?(:update, object)
end
def can_delete
scope.can?(:destroy, object)
end
end
BUT I really want to all abilities (:read and :create) for CurrentUser when s/he sign in to hide whatever the user hasn't permission to.
How do I get CurrentUser abilities as a hash?