X-Git-Url: https://vcs.fsf.org/?p=rainbowstream.git;a=blobdiff_plain;f=rainbowstream%2Frainbow.py;h=bb34bdbe36e28c27a4c98672bf8e42fbf0e5fb05;hp=129ad29743e6183a30049958faba46661e4567ca;hb=3343f4cf008e1b517a7af3e43ae7eb2cf0a46eaf;hpb=67eccba1a13ec517e653c42340ff4f645d98e8b9 diff --git a/rainbowstream/rainbow.py b/rainbowstream/rainbow.py index 129ad29..bb34bdb 100644 --- a/rainbowstream/rainbow.py +++ b/rainbowstream/rainbow.py @@ -885,7 +885,7 @@ def mute(): rel = t.mutes.users.create(screen_name=screen_name[1:]) if isinstance(rel, dict): printNicely(green(screen_name + ' is muted.')) - c['IGNORE_LIST'] += [unc(screen_name)] + c['IGNORE_LIST'] += [screen_name] c['IGNORE_LIST'] = list(set(c['IGNORE_LIST'])) else: printNicely(red(rel)) @@ -1979,8 +1979,6 @@ def listen(): g['prefix'] = False else: g['prefix'] = True - # Release the semaphore lock - c['lock'] = False except EOFError: printNicely('') except TwitterHTTPError as e: @@ -1988,6 +1986,9 @@ def listen(): except Exception: debug_option() printNicely(red('OMG something is wrong with Twitter API right now.')) + finally: + # Release the semaphore lock + c['lock'] = False def reconn_notice():