Skip to content

Commit 4f933bd

Browse files
STY: Apply ruff/flake8-simplify rule SIM211
SIM211 Use `not ...` instead of `False if ... else True`
1 parent 24d6360 commit 4f933bd

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

niworkflows/reports/core.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -463,8 +463,7 @@ def _process_orderings(orderings, layout):
463463
]
464464
# if all values are None for an entity, we do not want to keep that entity
465465
keep_idx = [
466-
False if (len(val_set) == 1 and None in val_set) or not val_set else True
467-
for val_set in unique_values
466+
not (len(val_set) == 1 and None in val_set or not val_set) for val_set in unique_values
468467
]
469468
# the "kept" entities
470469
entities = list(compress(orderings, keep_idx))

0 commit comments

Comments
 (0)