Skip to content

Commit

Permalink
chore: cleanup my booboo
Browse files Browse the repository at this point in the history
  • Loading branch information
Topvennie committed May 15, 2024
1 parent 087a8f4 commit cac233a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend/api/serializers/docker_serializer.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ def validate(self, attrs):

if not self.partial:
data["owner"] = self.context["request"].user
else:
data["owner"] = data["owner"] if "owner" in data else self.instance.owner
elif "owner" not in data:
data["owner"] = self.instance.owner

if "public" in data and data["public"] and not data["owner"].is_staff:
raise ValidationError(_("docker.errors.custom"))
Expand Down

0 comments on commit cac233a

Please sign in to comment.