Skip to content

Commit b71240d

Browse files
committed
fixed unecessary end line operator for empty
1 parent 1379566 commit b71240d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/textwrap.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -435,7 +435,7 @@ def dedent(text):
435435
margin = os.path.commonprefix([line for line in lines if line.strip()])
436436
margin_len = len(margin) - len(margin.lstrip())
437437

438-
return "\n".join([line[margin_len:] if line.strip() else "\n" if line and line[-1] == "\n" else "" for line in lines])
438+
return "\n".join([line[margin_len:] if line.strip() else "" for line in lines])
439439

440440

441441
def indent(text, prefix, predicate=None):

0 commit comments

Comments
 (0)