This commit is contained in:
deathbybandaid 2023-01-07 11:29:39 -05:00
parent 966a8a1e9b
commit 00c4b3bc7a

View File

@ -93,13 +93,12 @@ def do_reverse_recursive_directory_search(arr_file_path):
def get_file_path_list(arr):
file_path_env_list = expected_paths_env_variables[arr["type"]][arr["event_type"]]
valid_keys = [x for x in file_path_env_list if x in os.environ]
if not len(valid_keys):
invalid_keys = [x for x in file_path_env_list if x not in os.environ]
if len(invalid_keys):
for x in invalid_keys:
loggit("%s Environment variable was missing." % x, True)
valid_keys = [x for x in file_path_env_list if x in os.environ]
if not len(valid_keys):
loggit("%s Environment variable was missing.\n" % x)
sys.exit(1)
env_paths = []