summaryrefslogtreecommitdiff
path: root/sphinx/io.py
diff options
context:
space:
mode:
authorJon Dufresne <jon.dufresne@gmail.com>2018-09-11 05:50:55 -0700
committerJon Dufresne <jon.dufresne@gmail.com>2018-09-11 06:03:34 -0700
commit0d6be504ea4afc786b40ff8b87193ccdb0796951 (patch)
tree767ba9df7dc8759aaa588510121828b5d23becac /sphinx/io.py
parent844a3a5c226ff8891a1ce139f10ac92157c75da5 (diff)
downloadsphinx-git-0d6be504ea4afc786b40ff8b87193ccdb0796951.tar.gz
Remove use of six.iteritems()
In Python 3, dict.items() is always an iterator.
Diffstat (limited to 'sphinx/io.py')
-rw-r--r--sphinx/io.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/sphinx/io.py b/sphinx/io.py
index ad76c2afb..f18a1e95f 100644
--- a/sphinx/io.py
+++ b/sphinx/io.py
@@ -18,7 +18,7 @@ from docutils.parsers.rst import Parser as RSTParser
from docutils.readers import standalone
from docutils.statemachine import StringList, string2lines
from docutils.writers import UnfilteredWriter
-from six import text_type, iteritems
+from six import text_type
from typing import Any, Union # NOQA
from sphinx.deprecation import RemovedInSphinx30Warning
@@ -282,7 +282,7 @@ class FiletypeNotFoundError(Exception):
def get_filetype(source_suffix, filename):
# type: (Dict[unicode, unicode], unicode) -> unicode
- for suffix, filetype in iteritems(source_suffix):
+ for suffix, filetype in source_suffix.items():
if filename.endswith(suffix):
# If default filetype (None), considered as restructuredtext.
return filetype or 'restructuredtext'