def METHOD_NAME(value, exclude=None):
    try:
        user = User.objects.get_by_email(value)
        if not exclude or user.pk != exclude.pk:
            raise ValidationError(
                pgettext_lazy(
                    "user email validator", "This e-mail address is not available."
                )
            )
    except User.DoesNotExist:
        pass