From c07a251469d472c031fe5de5cd88c8319a2f0e87 Mon Sep 17 00:00:00 2001 From: shekhar-cis Date: Thu, 12 May 2022 15:45:33 +0530 Subject: [PATCH] Removed search_address method as staticmethod --- src/bmconfigparser.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/bmconfigparser.py b/src/bmconfigparser.py index 729eeb22..0e918259 100644 --- a/src/bmconfigparser.py +++ b/src/bmconfigparser.py @@ -196,10 +196,10 @@ class BMConfigParser(configparser.ConfigParser): return False return True - @staticmethod - def search_addresses(address, searched_text): + def search_addresses(self, address, searched_text): """Return the searched label of MyAddress""" - return [x for x in [BMConfigParser().get(address, 'label').lower(), + # import pdb; pdb.set_trace() + return [x for x in [self.get(address, 'label').lower(), address.lower()] if searched_text in x] def disable_address(self, address):