From 66f05b9840a6432c78cfb4a38f9df997592d7c6f Mon Sep 17 00:00:00 2001 From: kseen Date: Sun, 18 Aug 2024 09:40:44 +0300 Subject: [PATCH] More readable code in DB console [no_ci] --- src/db_console.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/db_console.py b/src/db_console.py index dbc8000..09fe06c 100644 --- a/src/db_console.py +++ b/src/db_console.py @@ -73,11 +73,11 @@ def drop(parameters, arguments): data_pick = data_pick[data_pick['comment'].fillna('').str.contains(arguments['comment-part'])] data_drop = read_csv(DB_FILE) Logger.info(f"Dropping {len(data_pick)} entries") - ans = None + answer = None if len(data_pick) != 0: - ans = input(f"{colorama.Fore.RED}ARE YOU SURE "\ + answer = input(f"{colorama.Fore.RED}ARE YOU SURE "\ + f"you want to DROP {len(data_pick)} entries? [y/N]{colorama.Style.RESET_ALL}") - if ans.lower() != 'y': + if answer.lower() != 'y': Logger.info("Aborted") return data_drop = data_drop[~data_drop.isin(data_pick)].dropna()