summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorByeonghoon Yoo <bh322yoo@gmail.com>2019-11-06 00:28:09 +0900
committerByeonghoon Yoo <bh322yoo@gmail.com>2019-11-06 00:28:09 +0900
commit705c16a2686ef561112854f180b7c79377049922 (patch)
treeef2bc2c2eacad4d46956e0b8bddeca3bc66946c7 /src
parentd23f77d06e8d12f961b23b7a5be0c24c62f1417e (diff)
downloadflake8-705c16a2686ef561112854f180b7c79377049922.tar.gz
Fix codes
Diffstat (limited to 'src')
-rw-r--r--src/flake8/processor.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/flake8/processor.py b/src/flake8/processor.py
index d92f0ba..0fd650b 100644
--- a/src/flake8/processor.py
+++ b/src/flake8/processor.py
@@ -36,7 +36,6 @@ class FileProcessor(object):
- :attr:`blank_before`
- :attr:`blank_lines`
- :attr:`checker_state`
- - :attr:`disable_noqa`
- :attr:`indent_char`
- :attr:`indent_level`
- :attr:`line_number`
@@ -78,8 +77,6 @@ class FileProcessor(object):
self._checker_states = {} # type: Dict[str, Dict[Any, Any]]
#: Current checker state
self.checker_state = {} # type: Dict[Any, Any]
- #: Disable all noqa comments
- self.disable_noqa = options.disable_noqa # type: bool
#: User provided option for hang closing
self.hang_closing = options.hang_closing
#: Character used for indentation
@@ -349,8 +346,10 @@ class FileProcessor(object):
:rtype:
bool
"""
- if not self.disable_noqa \
- and any(defaults.NOQA_FILE.match(line) for line in self.lines):
+ if (
+ not self.options.disable_noqa
+ and any(defaults.NOQA_FILE.match(line) for line in self.lines)
+ ):
return True
elif any(defaults.NOQA_FILE.search(line) for line in self.lines):
LOG.warning(