def set_search_info(self, engine, text): if not searchengines.get_engine_for_name(engine): logging.warn('Manager asked to set engine to non-existent %s', engine) self.perform_search(searchengines.get_last_engine().name, '') return self.engine = engine self.text = text searchengines.set_last_engine(self.engine)
def set_search_info(self, engine, text): if not searchengines.get_engine_for_name(engine): logging.info('Manager asked to set engine to non-existent %s. ' 'Probably engine has been removed.', engine) return self.engine = engine self.text = text searchengines.set_last_engine(self.engine)
def save_search(self): m = messages.NewFeedSearchEngine( searchengines.get_engine_for_name(self.engine), self.text) m.send_to_backend()