summaryrefslogtreecommitdiff
path: root/pyflakes/api.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyflakes/api.py')
-rw-r--r--pyflakes/api.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/pyflakes/api.py b/pyflakes/api.py
index b701ec5..cd4d943 100644
--- a/pyflakes/api.py
+++ b/pyflakes/api.py
@@ -44,8 +44,7 @@ def check(codeString, filename, reporter=None):
reporter.unexpectedError(filename, 'problem decoding source')
return 1
# Okay, it's syntactically valid. Now check it.
- file_tokens = checker.make_tokens(codeString)
- w = checker.Checker(tree, file_tokens=file_tokens, filename=filename)
+ w = checker.Checker(tree, filename=filename)
w.messages.sort(key=lambda m: m.lineno)
for warning in w.messages:
reporter.flake(warning)