mirror of
https://github.com/rwinkhart/sshyp.git
synced 2026-09-05 16:47:14 -04:00
Do not append extra new lines in line_edit
Former-commit-id: b2aefd5723c643f625865ea76957b2dbe560b58f Former-commit-id: 194dd58228db64c0d55089edfe60055ed9492860
This commit is contained in:
+1
-1
@@ -249,7 +249,7 @@ def target_type_check(_target_name, _expected_type=True, _error=False):
|
|||||||
def line_edit(_lines, _edit_data, _edit_line):
|
def line_edit(_lines, _edit_data, _edit_line):
|
||||||
# ensure enough lines are present for edited field
|
# ensure enough lines are present for edited field
|
||||||
while len(_lines) < _edit_line + 1:
|
while len(_lines) < _edit_line + 1:
|
||||||
_lines.append('\n')
|
_lines.append('')
|
||||||
# write the edited field
|
# write the edited field
|
||||||
_lines[_edit_line] = _edit_data.rstrip()
|
_lines[_edit_line] = _edit_data.rstrip()
|
||||||
return _lines
|
return _lines
|
||||||
|
|||||||
Reference in New Issue
Block a user