diff options
author | Ask Solem <ask@celeryproject.org> | 2014-01-13 15:15:20 +0000 |
---|---|---|
committer | Ask Solem <ask@celeryproject.org> | 2014-01-13 15:15:20 +0000 |
commit | f612a949f9413fc87389ac85976b42bb39a81b1c (patch) | |
tree | 66d45797738f7dd09796a75657fbd420c037f0e8 /docs | |
parent | ed6788c5ad79e577547fd603442835a5abe605bc (diff) | |
download | kombu-f612a949f9413fc87389ac85976b42bb39a81b1c.tar.gz |
Improve example in consumer user guide. Closes #298
Diffstat (limited to 'docs')
-rw-r--r-- | docs/userguide/consumers.rst | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/docs/userguide/consumers.rst b/docs/userguide/consumers.rst index 76c53638..cccbd4ac 100644 --- a/docs/userguide/consumers.rst +++ b/docs/userguide/consumers.rst @@ -38,9 +38,8 @@ Draining events from several consumers: from kombu.utils import nested with connection.channel(), connection.channel() as (channel1, channel2): - consumers = [Consumer(channel1, queues1, accept=['json']), - Consumer(channel2, queues2, accept=['json'])] - with nested(\*consumers): + with nested(Consumer(channel1, queues1, accept=['json']), + Consumer(channel2, queues2, accept=['json'])): connection.drain_events(timeout=1) |