Beispiel #1
0
		def _new( request, * args, ** kwargs ):
			if cookie.currentlyTraveling( request ):
				localThreadStorage.currentlyTravelingTo = cookie.currentlyTravelingTo( request )
				try:
					return method( request, * args, ** kwargs )
				finally:
					del localThreadStorage.currentlyTravelingTo
			else:
				assert not hasattr( localThreadStorage, 'currentlyTravelingTo' ) 
				return method( request, * args, ** kwargs )
Beispiel #2
0
 def _new(request, *args, **kwargs):
     if cookie.currentlyTraveling(request):
         localThreadStorage.currentlyTravelingTo = cookie.currentlyTravelingTo(
             request)
         try:
             return method(request, *args, **kwargs)
         finally:
             del localThreadStorage.currentlyTravelingTo
     else:
         assert not hasattr(localThreadStorage, 'currentlyTravelingTo')
         return method(request, *args, **kwargs)
def timeMachine_currentlyTraveling( request ):
	return cookie.currentlyTraveling( request )
Beispiel #4
0
def timeMachine_currentlyTraveling(request):
    return cookie.currentlyTraveling(request)
Beispiel #5
0
 def _new(request, *args, **kwargs):
     if cookie.currentlyTraveling(request):
         return shortcuts.redirect(
             "/timemachine/notAllowedToChangePast")
     assert not hasattr(localThreadStorage, 'currentlyTravelingTo')
     return method(request, *args, **kwargs)
Beispiel #6
0
			def _new( request, * args, ** kwargs ):
				if cookie.currentlyTraveling( request ):
					return shortcuts.redirect( "/timemachine/notAllowedToChangePast" )
				assert not hasattr( localThreadStorage, 'currentlyTravelingTo' ) 
				return method( request, * args, ** kwargs )