catch IOError when config not exists
authorvunhat_minh <vunhat_minh@dwango.co.jp>
Fri, 22 Aug 2014 04:29:30 +0000 (13:29 +0900)
committervunhat_minh <vunhat_minh@dwango.co.jp>
Fri, 22 Aug 2014 04:29:30 +0000 (13:29 +0900)
rainbowstream/config.py

index 9cc2310af1209112296ee9506db7e196a48fe60d..58f747de33cf8ab627f1227137cc9e30be5227bc 100644 (file)
@@ -162,7 +162,7 @@ def init_config():
         data = load_config(rainbow_config)
         for d in data:
             c[d] = data[d]
-    except ValueError as e:
+    except (IOError, ValueError) as e:
         c['USER_JSON_ERROR'] = str(e)
     # Load default theme
     theme_file = os.path.dirname(__file__) + \