Skip to content

Commit

Permalink
Merge pull request #98 from lvalerio/master
Browse files Browse the repository at this point in the history
make_vcsp_2018.py: Fixed uninitialzied variable
  • Loading branch information
lamw committed Jun 2, 2021
2 parents 98195ec + 6a9561e commit cf06468
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/make_vcsp_2018.py
Expand Up @@ -127,6 +127,7 @@ def _dir2item(path, directory, md5_enabled, lib_id):
vcsp_type = VCSP_TYPE_OTHER
folder = ""
folder_md5 = ""
is_vapp = ""
for f in os.listdir(path):
if f == ".DS_Store" or f == ''.join((directory, os.extsep, FORMAT)):
continue
Expand Down Expand Up @@ -418,7 +419,7 @@ def make_vcsp_s3(lib_name, lib_path, skip_cert):
update_items_json = False

response = s3_client.list_objects_v2(Bucket=bucket_name, Prefix=lib_folder_path, Delimiter="/")
if response['CommonPrefixes']:
if 'CommonPrefixes' in response:
# skip items generation if no child folders
for child in response['CommonPrefixes']:
p = child['Prefix']
Expand Down

0 comments on commit cf06468

Please sign in to comment.