Commit 834eb793 authored by Sam Rushing's avatar Sam Rushing

channel.forget_consumer: handle KeyError.

parent 1744b403
......@@ -463,7 +463,10 @@ class channel:
self.consumers[con.tag] = con
def forget_consumer (self, tag):
del self.consumers[tag]
try:
del self.consumers[tag]
except KeyError:
pass
def notify_consumers_of_close (self):
for _, con in self.consumers.iteritems():
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment