Fix up merge
This commit is contained in:
parent
37f8ed0a3f
commit
be46470e55
@ -681,14 +681,17 @@ def _maybe_empty_lines(self, current_line: Line) -> Tuple[int, int]:
|
||||
|
||||
# In preview mode, always allow blank lines, except right before a function
|
||||
# docstring
|
||||
is_empty_first_line_ok = (
|
||||
not is_docstring(current_line.leaves[0])
|
||||
or (
|
||||
is_empty_first_line_ok = not is_docstring(current_line.leaves[0]) or (
|
||||
self.previous_line
|
||||
and self.previous_line.leaves[0]
|
||||
and self.previous_line.leaves[0].parent
|
||||
and not is_funcdef(self.previous_line.leaves[0].parent)
|
||||
)
|
||||
|
||||
if (
|
||||
self.previous_line
|
||||
and self.previous_line.opens_block
|
||||
and not is_empty_first_line_ok
|
||||
):
|
||||
return 0, 0
|
||||
return before, 0
|
||||
|
Loading…
Reference in New Issue
Block a user