Browse Source

Merge branch '3.0'

Ask Solem 12 years ago
parent
commit
2f40d121a3
1 changed files with 3 additions and 3 deletions
  1. 3 3
      celery/app/task.py

+ 3 - 3
celery/app/task.py

@@ -267,9 +267,9 @@ class Task(object):
         if not was_bound:
         if not was_bound:
             self.annotate()
             self.annotate()
 
 
-        from celery.utils.threads import LocalStack
-        self.request_stack = LocalStack()
-        self.request_stack.push(Context())
+            from celery.utils.threads import LocalStack
+            self.request_stack = LocalStack()
+            self.request_stack.push(Context())
 
 
         # PeriodicTask uses this to add itself to the PeriodicTask schedule.
         # PeriodicTask uses this to add itself to the PeriodicTask schedule.
         self.on_bound(app)
         self.on_bound(app)