def METHOD_NAME(self, attrs):
    remove = attrs.get("remove")
    role = attrs.get("role")
    organization = attrs.get("organization")
    username = attrs.get("username")
    # check if roles are downgrading and the user is the last admin
    if username and (remove or role != OwnerRole.name):
        user = User.objects.get(username=username)
        owners = _get_owners(organization)
        if user in owners and len(owners) <= 1:
            raise serializers.ValidationError(
                _("Organization cannot be without an owner")
            )
    return attrs