Skip to content

Commit

Permalink
fix: Set error value from validation exception properly for feature s…
Browse files Browse the repository at this point in the history
…eralizer (#3809)
  • Loading branch information
zachaysan authored Apr 19, 2024
1 parent 10b14fd commit 18d8214
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/features/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ def save(self, **kwargs):
try:
return super().save(**kwargs)
except django.core.exceptions.ValidationError as e:
raise serializers.ValidationError(e.message)
raise serializers.ValidationError(str(e))

def validate_feature(self, feature):
if self.instance and self.instance.feature_id != feature.id:
Expand Down

0 comments on commit 18d8214

Please sign in to comment.