mirror of
https://github.com/aclist/dztui.git
synced 2026-10-30 06:32:53 +01:00
fix: strip newlines in history file
This commit is contained in:
1 parent
5a33591d6a
commit
c5b13ff0f3
1 file changed
+1
-1
+1
-1
@@ -780,7 +780,7 @@ def set_surrounding_margins(widget: Gtk.Widget, margin: int) -> None:
|
|||||||
def query_history() -> list | None:
|
def query_history() -> list | None:
|
||||||
try:
|
try:
|
||||||
with open(history_file, "r") as f:
|
with open(history_file, "r") as f:
|
||||||
rows = [row for row in f]
|
rows = [row.rstrip("\n") for row in f]
|
||||||
except OSError:
|
except OSError:
|
||||||
rows = None
|
rows = None
|
||||||
finally:
|
finally:
|
||||||
|
|||||||
Reference in new issue
Block a user