From: tierno Date: Wed, 12 Feb 2020 10:46:51 +0000 (+0000) Subject: fix fslocal file_exists X-Git-Tag: v7.1.0rc1~8 X-Git-Url: https://osm.etsi.org/gitweb/?p=osm%2Fcommon.git;a=commitdiff_plain;h=e458cd8c564e13a04656e6a8337b7d5225cb1f8d fix fslocal file_exists Change-Id: I871a4912741a0542f3b70d1fdb0d6ca118aa0da3 Signed-off-by: tierno --- diff --git a/osm_common/fslocal.py b/osm_common/fslocal.py index 7794754..b90b25e 100644 --- a/osm_common/fslocal.py +++ b/osm_common/fslocal.py @@ -93,6 +93,8 @@ class FsLocal(FsBase): else: f = "/".join(storage) if os.path.exists(self.path + f): + if not mode: + return True if mode == "file" and os.path.isfile(self.path + f): return True if mode == "dir" and os.path.isdir(self.path + f):