summaryrefslogtreecommitdiff
path: root/flake8/processor.py
diff options
context:
space:
mode:
authorIan Cordasco <graffatcolmingov@gmail.com>2016-03-10 19:00:07 -0600
committerIan Cordasco <graffatcolmingov@gmail.com>2016-03-10 19:00:07 -0600
commitda2182151773e5e37faa87ad607308694e6c1997 (patch)
tree240d9afa51e1a5ba1d38a8dfdee89e9731472519 /flake8/processor.py
parent36fb688f97d69d1ba0e1ea7bd6502ec7fe8b3141 (diff)
downloadflake8-da2182151773e5e37faa87ad607308694e6c1997.tar.gz
Make flake8 actually work
Diffstat (limited to 'flake8/processor.py')
-rw-r--r--flake8/processor.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/flake8/processor.py b/flake8/processor.py
index 062006d..88514e5 100644
--- a/flake8/processor.py
+++ b/flake8/processor.py
@@ -80,7 +80,7 @@ class FileProcessor(object):
#: Total number of lines in the file
self.total_lines = len(self.lines)
#: Verbosity level of Flake8
- self.verbosity = options.verbosity
+ self.verbosity = options.verbose
@contextlib.contextmanager
def inside_multiline(self, line_number):
@@ -302,10 +302,12 @@ def token_is_comment(token):
def count_parentheses(current_parentheses_count, token_text):
"""Count the number of parentheses."""
+ current_parentheses_count = current_parentheses_count or 0
if token_text in '([{':
return current_parentheses_count + 1
elif token_text in '}])':
return current_parentheses_count - 1
+ return current_parentheses_count
def log_token(log, token):