Did I find the right examples for you? yes no

All Samples(6)  |  Call(2)  |  Derive(0)  |  Import(4)

src/d/j/dj-stripe-0.3.3/djstripe/mixins.py   dj-stripe(Download)
from .models import Customer, CurrentSubscription
from . import settings as app_settings
from .utils import user_has_active_subscription
 
ERROR_MSG = (
    def dispatch(self, request, *args, **kwargs):
        if not user_has_active_subscription(request.user):
            msg = "Your account is inactive. Please renew your subscription"
            messages.info(request, msg, fail_silently=True)
            return redirect("djstripe:subscribe")

src/d/j/dj-stripe-HEAD/djstripe/mixins.py   dj-stripe(Download)
from .models import Customer, CurrentSubscription
from . import settings as app_settings
from .utils import user_has_active_subscription
 
ERROR_MSG = (
    def dispatch(self, request, *args, **kwargs):
        if not user_has_active_subscription(request.user):
            msg = "Your account is inactive. Please renew your subscription"
            messages.info(request, msg, fail_silently=True)
            return redirect("djstripe:subscribe")

src/d/j/dj-stripe-0.3.3/djstripe/decorators.py   dj-stripe(Download)
from django.shortcuts import redirect
 
from .utils import user_has_active_subscription
 
 

src/d/j/dj-stripe-HEAD/djstripe/decorators.py   dj-stripe(Download)
from django.shortcuts import redirect
 
from .utils import user_has_active_subscription