Readability: reduce boolean nesting

This commit is contained in:
James Addison 2021-02-09 21:13:57 +00:00 committed by Łukasz Langa
parent 24700806f6
commit 22127c633e

View File

@ -2712,7 +2712,8 @@ def init_st(ST: Type[StringTransformer]) -> StringTransformer:
transformers: List[Transformer]
if (
not line.contains_uncollapsable_type_comments()
and not (line.should_split or line.magic_trailing_comma)
and not line.should_split
and not line.magic_trailing_comma
and (
is_line_short_enough(line, line_length=mode.line_length, line_str=line_str)
or line.contains_unsplittable_type_ignore()