diff --git a/plugins/Mute/MutePlugin.py b/plugins/Mute/MutePlugin.py index 6779e886..af967d25 100644 --- a/plugins/Mute/MutePlugin.py +++ b/plugins/Mute/MutePlugin.py @@ -10,9 +10,12 @@ from util import helper if os.path.isfile("%s/mutes.json" % config.data_dir): - mutes = json.load(open("%s/mutes.json" % config.data_dir))["mutes"] + try: + mutes = json.load(open("%s/mutes.json" % config.data_dir))["mutes"] + except Exception, err: + mutes = {} else: - open("%s/mutes.json" % config.data_dir, "w").write("{'mutes': {}}") + open("%s/mutes.json" % config.data_dir, "w").write('{"mutes": {}}') mutes = {} if "_" not in locals(): diff --git a/src/Config.py b/src/Config.py index 9e382779..e3cdb699 100644 --- a/src/Config.py +++ b/src/Config.py @@ -10,7 +10,7 @@ class Config(object): def __init__(self, argv): self.version = "0.5.2" - self.rev = 1882 + self.rev = 1884 self.argv = argv self.action = None self.config_file = "zeronet.conf"