summaryrefslogtreecommitdiff
path: root/django
diff options
context:
space:
mode:
Diffstat (limited to 'django')
-rw-r--r--django/core/files/base.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/core/files/base.py b/django/core/files/base.py
index b1325291c6..641ff924c6 100644
--- a/django/core/files/base.py
+++ b/django/core/files/base.py
@@ -104,7 +104,7 @@ class File(FileProxyMixin):
# If this is the end of a line, yield
# otherwise, wait for the next round
- if line[-1] in ('\n', '\r'):
+ if line[-1:] in (b'\n', b'\r'):
yield line
else:
buffer_ = line