Skip to content

Commit 128be4b

Browse files
committed
Applied a patch from production to trunk.
- Legacy-Id: 13214
1 parent 1f2044b commit 128be4b

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

ietf/doc/models.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -419,13 +419,11 @@ def text(self):
419419
try:
420420
with open(path, 'rb') as file:
421421
raw = file.read()
422-
except IOError as e:
423-
import sys
424-
logger.error("IOError for %s: %s", path, e, exc_info=sys.exc_info())
422+
except IOError:
425423
return None
426424
try:
427425
text = raw.decode('utf-8')
428-
except UnicodeDecodeError as e:
426+
except UnicodeDecodeError:
429427
text = raw.decode('latin-1')
430428
#
431429
return text

0 commit comments

Comments
 (0)