Fix previous commit on python 2.

This commit is contained in:
Valentin Lorentz 2018-06-27 11:10:14 +02:00
parent 1840b94453
commit 50c41f5862
1 changed files with 2 additions and 1 deletions

View File

@ -30,6 +30,7 @@
import csv
import time
import codecs
import datetime
import supybot.log as log
@ -71,7 +72,7 @@ class Later(callbacks.Plugin):
def _openNotes(self):
try:
fd = open(self.filename, encoding='utf8')
fd = codecs.open(self.filename, encoding='utf8')
except EnvironmentError as e:
self.log.warning('Couldn\'t open %s: %s', self.filename, e)
return