From 15fc878acad4f80b8ff1c46ba31c6876e5520577 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dani=C3=ABl=20van=20Noord?= <13665637+DanielNoord@users.noreply.github.com> Date: Mon, 5 Sep 2022 10:35:33 +0200 Subject: [PATCH] Change disable --- pylint/checkers/variables.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pylint/checkers/variables.py b/pylint/checkers/variables.py index 74b8c4c706..1236d4fb33 100644 --- a/pylint/checkers/variables.py +++ b/pylint/checkers/variables.py @@ -2209,9 +2209,8 @@ def _loopvar_name(self, node: astroid.Name) -> None: # scope lookup rules would need to be changed to return the initial # assignment (which does not exist in code per se) as well as any later # modifications. - # pylint: disable-next=too-many-boolean-expressions if ( - not astmts + not astmts # pylint: disable=too-many-boolean-expressions or ( astmts[0].parent == astmts[0].root() and astmts[0].parent.parent_of(node)