diff options
-rwxr-xr-x | pycodestyle.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/pycodestyle.py b/pycodestyle.py index 47ab5ce..7f00739 100755 --- a/pycodestyle.py +++ b/pycodestyle.py @@ -497,10 +497,9 @@ def whitespace_around_keywords(logical_line): if sys.version_info >= (3, 10): match = MATCH_CASE_REGEX.match(logical_line) if match: - whitespace = match.groups()[0] - if whitespace == ' ': + if match[1] == ' ': return - if whitespace == '': + if match[1] == '': yield match.start(1), "E275 missing whitespace after keyword" else: yield match.start(1), "E271 multiple spaces after keyword" |