From: beierlm Date: Wed, 13 Apr 2022 10:28:58 +0000 (-0400) Subject: Bug 1989 Do not use trailing / for directory X-Git-Tag: v12.0.0rc1~25 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=81b30e916f0cdbcfe0da4868325591c34fb5acb2;p=osm%2FNBI.git Bug 1989 Do not use trailing / for directory When storing package contents in fsmongo, the tar format does not have a trailing / on directories, but zip format does. As a result, when searching for the charm directory, logic was added to append the / on the end of the directory name. This is no longer needed as the reverse sync is being used now to store package content and it handles directory names properly. Fixes bug 1989 Change-Id: I31540c817113f393e222ae47c3420f374769e3ed Signed-off-by: beierlm --- diff --git a/osm_nbi/descriptor_topics.py b/osm_nbi/descriptor_topics.py index 072485a..4661964 100644 --- a/osm_nbi/descriptor_topics.py +++ b/osm_nbi/descriptor_topics.py @@ -973,7 +973,6 @@ class VnfdTopic(DescriptorTopic): if file: return self.fs.file_exists("{}/{}".format(f, file), "file") else: - f = f+"/" if self.fs.file_exists(f, "dir"): if self.fs.dir_ls(f): return True