fix issues caused by dfe1ac8d

fix #924
fix #923
This commit is contained in:
alfrix 2023-03-11 16:40:06 -06:00
parent 094b90cf86
commit 87c3f03719

View File

@ -153,11 +153,14 @@ class Printer:
return []
def get_config_section(self, section):
return self.config[section] if section in self.config else False
def get_macro(self, macro):
return next(
(
self.config[key]
for key in self.config.keys()
if key.find(section) > -1
if key.find(macro) > -1
),
False,
)