Esempio n. 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 )
Esempio n. 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)
Esempio n. 3
0
def timeMachine_currentlyTraveling( request ):
	return cookie.currentlyTraveling( request )
Esempio n. 4
0
def timeMachine_currentlyTraveling(request):
    return cookie.currentlyTraveling(request)
Esempio n. 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)
Esempio n. 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 )