Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix bug in Channel.SyncWrapper.__eq__ comparison
  • Loading branch information
awestendorf committed May 7, 2012
1 parent 44c2da7 commit 5b9d87d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG
Expand Up @@ -16,6 +16,8 @@ the broker
Fixed bug in Channel.clear_synchronous_cb which needs to return the argument
if no matching callback was found. This fixes a bug in ProtocolClass.dispatch.

Fix isinstance parameter ordering in Channel.SyncWrapper.__eq__


0.5.0
=====
Expand Down
2 changes: 1 addition & 1 deletion haigha/channel.py
Expand Up @@ -18,7 +18,7 @@ def __init__(self, cb):
self._result = None
def __eq__(self, other):
return other==self._cb or \
(isinstance(SyncWrapper,other) and other._cb==self._cb)
(isinstance(other,SyncWrapper) and other._cb==self._cb)
def __call__(self, *args, **kwargs):
self._read = False
self._result = self._cb(*args, **kwargs)
Expand Down

0 comments on commit 5b9d87d

Please sign in to comment.