From cebdc6aff0657b6d830a49fd771eaf52812932d3 Mon Sep 17 00:00:00 2001 From: Benawi Adha Date: Sun, 11 Dec 2022 07:21:54 +0700 Subject: Simplify logic --- src/epy_reader/reader.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/epy_reader/reader.py b/src/epy_reader/reader.py index cd56ac1..60feed6 100644 --- a/src/epy_reader/reader.py +++ b/src/epy_reader/reader.py @@ -452,8 +452,7 @@ class Reader: if not self.search_data: candidate_text = self.input_prompt(" Regex:") - # if isinstance(candidate_text, str) and candidate_text != "": - if isinstance(candidate_text, str) and candidate_text: + if isinstance(candidate_text, str): self.search_data = SearchData(value=candidate_text) else: assert isinstance(candidate_text, NoUpdate) or isinstance(candidate_text, Key) -- cgit