Ask Solem 11 anos atrás
pai
commit
0fbab3ab3f
1 arquivos alterados com 2 adições e 3 exclusões
  1. 2 3
      docs/userguide/tasks.rst

+ 2 - 3
docs/userguide/tasks.rst

@@ -997,12 +997,11 @@ will do roughly this behind the scenes:
 
 
 .. code-block:: python
 .. code-block:: python
 
 
-    @app.task
-    class AddTask(Task):
+    class _AddTask(app.Task):
 
 
         def run(self, x, y):
         def run(self, x, y):
             return x + y
             return x + y
-    add = registry.tasks[AddTask.name]
+    add = app.tasks[_AddTask.name]
 
 
 
 
 Instantiation
 Instantiation