diff --git a/dissect/target/plugins/apps/other/env.py b/dissect/target/plugins/apps/other/env.py index 5257af938..b12a4ff2a 100644 --- a/dissect/target/plugins/apps/other/env.py +++ b/dissect/target/plugins/apps/other/env.py @@ -31,9 +31,11 @@ def envfile(self, env_path: str, extension: str = "env") -> Iterator[Environment if not env_path: self.target.log.error("No ``--path`` provided!") + return if not (path := self.target.fs.path(env_path)).exists(): self.target.log.error("Provided path %s does not exist!", path) + return for file in path.glob("**/*." + extension): if not file.is_file():