From 1623e4bc7ef5e7412277ca4429f2c2aa350de650 Mon Sep 17 00:00:00 2001 From: Austin Bozowski Date: Thu, 2 Jun 2022 20:31:36 +0000 Subject: [PATCH] Flatten with block --- examples/chef/chef.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/examples/chef/chef.py b/examples/chef/chef.py index 33c0f2a851c7d0..55fdd5f5ac28ec 100755 --- a/examples/chef/chef.py +++ b/examples/chef/chef.py @@ -149,12 +149,12 @@ def generate_device_manifest( def load_cicd_config() -> Dict[str, Any]: with open(_CICD_CONFIG_FILE_NAME) as config_file: config = json.loads(config_file.read()) - for platform_name, platform_config in config.items(): - has_build_dir = "build_dir" in platform_config - has_plat_label = "platform_label" in platform_config - if not has_build_dir or not has_plat_label: - flush_print(f"{platform_name} CICD config missing build_dir or platform_label") - exit(1) + for platform_name, platform_config in config.items(): + has_build_dir = "build_dir" in platform_config + has_plat_label = "platform_label" in platform_config + if not has_build_dir or not has_plat_label: + flush_print(f"{platform_name} CICD config missing build_dir or platform_label") + exit(1) return config