From 94f081ad5dc24535ce93fbf12cd18ebeee200074 Mon Sep 17 00:00:00 2001 From: Klaus Zerwes Date: Mon, 8 Aug 2022 20:48:48 +0200 Subject: [PATCH] fixed : Value 'config' is unsubscriptable --- fqcn-fixer.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fqcn-fixer.py b/fqcn-fixer.py index b6b5a11..bae8cb0 100755 --- a/fqcn-fixer.py +++ b/fqcn-fixer.py @@ -187,11 +187,11 @@ config = False if args.config: try: with open(args.config) as ymlfile: - config = yaml.load(ymlfile, Loader=yaml.BaseLoader) + _config = yaml.load(ymlfile, Loader=yaml.BaseLoader) except FileNotFoundError: pass -if config and 'exclude_paths' in config.keys(): - for ep in config['exclude_paths']: +if _config and 'exclude_paths' in _config.keys(): + for ep in _config['exclude_paths']: exclude_paths.append(os.path.abspath(ep)) # find files to parse