fix: is free to join if cost_to_join == 0

This commit is contained in:
Vlad Stan 2023-04-06 18:14:12 +03:00
parent 8ed361230b
commit dc50d3493d
2 changed files with 5 additions and 1 deletions

View file

@ -79,6 +79,10 @@ class PaymentSpec(Spec):
storage_cost_value = Field(0, alias="storageCostValue")
storage_cost_unit = Field("MB", alias="storageCostUnit")
@property
def is_free_to_join(self):
return not self.is_paid_relay or self.cost_to_join == 0
class WalletSpec(Spec):
wallet = Field("")