Exemplo n.º 1
0
    async def check_balance(self, ctx):

        if ctx.profile.balance > ctx.price.cost:
            return Success()
        else:
            return Failure()
Exemplo n.º 2
0
 async def one(self, ctx):
     return Failure("foo")
Exemplo n.º 3
0
    async def check_expiration(self, ctx):

        if ctx.subscription.is_expired():
            return Failure(Errors.forbidden)
        else:
            return Success()
Exemplo n.º 4
0
 def one(self, ctx):
     return Failure(self.Errors.foo)
Exemplo n.º 5
0
 def one(self, ctx):
     return Failure()
Exemplo n.º 6
0
 def three(self, ctx):
     return Failure()
Exemplo n.º 7
0
 def two(self, ctx):
     return Failure("'foo' is too big")