Skip to content

Commit

Permalink
Merge pull request #187 from UnitapApp/fix/prizetap-provider-dashboard
Browse files Browse the repository at this point in the history
Use get_constraint in createRaffle serializer
  • Loading branch information
ShayanShiravani authored Nov 18, 2023
2 parents 34ed7d4 + 09253f8 commit d6a2319
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion prizetap/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ def validate(self, data):
data["constraint_params"] = base64.b64decode(data["constraint_params"]).decode("utf-8")
if len(constraints) != 0:
for c in constraints:
constraint_class: ConstraintVerification = eval(c.name)
constraint_class: ConstraintVerification = get_constraint(c.name)
try:
if len(constraint_class.param_keys()) != 0:
constraint_class.is_valid_param_keys(constraint_params[c.name])
Expand Down

0 comments on commit d6a2319

Please sign in to comment.