summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimothy Crosley <timothy.crosley@gmail.com>2019-12-08 23:33:10 -0800
committerTimothy Crosley <timothy.crosley@gmail.com>2019-12-08 23:33:10 -0800
commit8c758856c69de5412f6e4daa551b79cc7f3c1bfb (patch)
treef2bf5b942e19b43c1e115560d56a056ac597a6a9
parent40e861d43bd57ca4562491ebd7d62f5a25b2b13e (diff)
downloadisort-8c758856c69de5412f6e4daa551b79cc7f3c1bfb.tar.gz
Explicity specify no output type
-rw-r--r--isort/parse.py8
1 files changed, 2 insertions, 6 deletions
diff --git a/isort/parse.py b/isort/parse.py
index e5999822..1681c6e3 100644
--- a/isort/parse.py
+++ b/isort/parse.py
@@ -470,10 +470,9 @@ def file_contents(contents: str, config: Config = DEFAULT_CONFIG) -> ParsedConte
def identify_contiguous_imports(
- input_stream: TextIO, output_stream: TextIO = None, config: Config = DEFAULT_CONFIG
-):
+ input_stream: TextIO, output_stream: TextIO, config: Config = DEFAULT_CONFIG
+) -> None:
"""Parses stream identifying sections of contiguous imports"""
- output_stream = StringIO() if output_stream is None else output_stream
import_section: str = ""
in_quote: str = ""
first_comment_index_start: int = -1
@@ -543,6 +542,3 @@ def identify_contiguous_imports(
output_stream.write(line)
not_imports = False
-
- output_stream.seek(0)
- return output_stream