diff --git a/beat/web/common/serializers.py b/beat/web/common/serializers.py index 05344e4daf42551e3d9abad94887b866db62d9bb..78b547c47b1baa70568e28a6bea02dc8d4f7e5ab 100644 --- a/beat/web/common/serializers.py +++ b/beat/web/common/serializers.py @@ -351,7 +351,7 @@ class ContributionCreationSerializer(serializers.ModelSerializer): ) if self.Meta.model.objects.filter( - author__username__iexact=user, name=name, version=version + author=user, name=name, version=version ).exists(): raise serializers.ValidationError( "{} {} version {} already exists on this account".format(