Skip to content

Commit

Permalink
grumble
Browse files Browse the repository at this point in the history
  • Loading branch information
twd2 authored Oct 6, 2017
1 parent 062360c commit 6c180ca
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions jd4/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

def _load_config():
try:
with open(_CONFIG_FILE, 'r', encoding='utf-8') as file:
with open(_CONFIG_FILE, 'rb') as file:
return yaml.load(file, Loader=yaml.RoundTripLoader)
except FileNotFoundError:
logger.error('Config file %s not found.', _CONFIG_FILE)
Expand All @@ -29,7 +29,7 @@ def _load_config():

async def save_config():
def do_save_config():
with open(_CONFIG_FILE, 'w') as file:
with open(_CONFIG_FILE, 'wb') as file:
yaml.dump(config, file, Dumper=yaml.RoundTripDumper)

await get_event_loop().run_in_executor(None, do_save_config)
Expand Down

0 comments on commit 6c180ca

Please sign in to comment.