Skip to content

Commit 2e85876

Browse files
committed
STYLE: Avoid difficult to read anit-pattern
Test for object identity should be 'is not' https://www.flake8rules.com/rules/E714.html
1 parent bb1c7b5 commit 2e85876

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Wrapping/Generators/Python/itkTemplate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ def __getitem__(self, parameters):
321321
"""
322322

323323
parameters_type = type(parameters)
324-
if not parameters_type is tuple and not parameters_type is list:
324+
if (parameters_type is not tuple) and (parameters_type is not list):
325325
# parameters is a single element.
326326
# include it in a list to manage the 2 cases in the same way
327327
parameters = [parameters]

0 commit comments

Comments
 (0)