Fix debug-dump-history behavior.

Ensure the file is closed before printing the success message. This will
hopefully fix the AppVeyor tests.
This commit is contained in:
Ryan Roden-Corrent 2017-07-06 08:02:16 -04:00
parent cee0aa3adc
commit 1dd5f06a4f

View File

@ -282,7 +282,7 @@ class WebHistory(sql.SqlTable):
try:
with open(dest, 'w', encoding='utf-8') as f:
f.write('\n'.join(lines))
message.info("Dumped history to {}".format(dest))
message.info("Dumped history to {}".format(dest))
except OSError as e:
raise cmdexc.CommandError('Could not write history: {}', e)