summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMads Jensen <mje@inducks.org>2018-01-27 10:22:12 +0100
committerOmer Katz <omer.drow@gmail.com>2018-01-27 11:22:12 +0200
commit537e973e7e697f6824472e2784053aeb1b07fed0 (patch)
treeddbec74323c977ad6bb72401d010c4c14aa3e54b
parent16ea4df21702a8bc4a639f83d687a257012af901 (diff)
downloadkombu-537e973e7e697f6824472e2784053aeb1b07fed0.tar.gz
Replaced a dict-construct with a dictionary comprehension. (#828)
-rw-r--r--kombu/transport/virtual/base.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/kombu/transport/virtual/base.py b/kombu/transport/virtual/base.py
index 8ccb8f6c..f09a7b3f 100644
--- a/kombu/transport/virtual/base.py
+++ b/kombu/transport/virtual/base.py
@@ -462,9 +462,9 @@ class Channel(AbstractChannel, base.StdChannel):
self.closed = False
# instantiate exchange types
- self.exchange_types = dict(
- (typ, cls(self)) for typ, cls in items(self.exchange_types)
- )
+ self.exchange_types = {
+ typ: cls(self) for typ, cls in items(self.exchange_types)
+ }
try:
self.channel_id = self.connection._avail_channel_ids.pop()