Skip to content

Commit

Permalink
Fix typo on hex serializer
Browse files Browse the repository at this point in the history
  • Loading branch information
Uxio0 committed Dec 13, 2023
1 parent 3ebe6b7 commit 421edec
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gnosis/eth/django/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,9 @@ def to_internal_value(self, data):
data_hex = HexBytes(data)
data_len = len(data_hex)
if self.min_length and data_len < self.min_length:
self.fail("min_length", min_length=data_len)
self.fail("min_length", min_length=self.min_length)
elif self.max_length and data_len > self.max_length:
self.fail("max_length", max_length=data_len)
self.fail("max_length", max_length=self.max_length)
return data_hex
except ValueError:
self.fail("invalid", value=data)
Expand Down

0 comments on commit 421edec

Please sign in to comment.