@require_http_methods(['GET'])
@login_required
@enforce_shopping_cart_enabled
def verify_cart(request):
 (is_any_course_expired, __, __, __) = verify_for_closed_enrollment(request.user)
 return JsonResponse({'is_course_enrollment_closed': is_any_course_expired})

@ require_http_methods ( [ 'GET' ] ) @ login_required @ enforce_shopping_cart_enabled def verify_cart ( request ) : ( is_any_course_expired , __ , __ , __ ) = verify_for_closed_enrollment ( request . user ) return JsonResponse ( { 'is_course_enrollment_closed' : is_any_course_expired } )
called when the user clicks the button to transfer control to cybersource .