Skip to content

Commit

Permalink
Update index.py
Browse files Browse the repository at this point in the history
  • Loading branch information
StrahinjaJacimovic authored Jul 21, 2024
1 parent 05d1bf9 commit bfb6091
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion scripts/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,10 @@ def index_release_to_elasticsearch(es : Elasticsearch, index_name, release_detai
}
else:
metadata_item = find_item_by_name(metadata_content[0], name_without_extension)
previous_metadata_item = find_item_by_name(metadata_content[1], name_without_extension)
if len(metadata_content) > 1:
previous_metadata_item = find_item_by_name(metadata_content[1], name_without_extension)
else:
previous_metadata_item = find_item_by_name(metadata_content[0], name_without_extension)

if metadata_item:
if previous_metadata_item:
Expand Down

0 comments on commit bfb6091

Please sign in to comment.