From 6fb8cc8e1ca3e5594c44953f66bbce13abd08e46 Mon Sep 17 00:00:00 2001 From: Casper da Costa-Luis Date: Sun, 10 Jan 2021 14:41:36 +0000 Subject: [PATCH] more pipe removal --- tqdm/tk.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tqdm/tk.py b/tqdm/tk.py index 505d368d..f8bb93e5 100644 --- a/tqdm/tk.py +++ b/tqdm/tk.py @@ -143,9 +143,8 @@ class tqdm_tk(std_tqdm): # pragma: no cover d['ncols'] = None text = self.format_meter(**d) # fixup only default bar format - if self.bar_format == "{l_bar}{r_bar}": - text = text.replace("||", "", 1) - self._tk_text_var.set(text) + self._tk_text_var.set( + text.replace("||", "", 1) if "{l_bar}{r_bar}" in self.bar_format else text) if not self._tk_dispatching: self._tk_window.update()