Skip to content
This repository has been archived by the owner on May 11, 2022. It is now read-only.

Commit

Permalink
Avoid unnecessary re-load of collection objects
Browse files Browse the repository at this point in the history
  • Loading branch information
cbeer committed Nov 16, 2016
1 parent a72e3fb commit f47f088
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/dor/models/releaseable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def get_release_tags_for_item_and_all_governing_sets
return_tags = release_nodes || {}
collections.each do |collection|
next if collection.id == id # recursive, so parents of parents are found, but we need to avoid an infinite loop if the collection references itself (i.e. bad data)
return_tags = combine_two_release_tag_hashes(return_tags, Dor.find(collection.id).get_release_tags_for_item_and_all_governing_sets)
return_tags = combine_two_release_tag_hashes(return_tags, collection.get_release_tags_for_item_and_all_governing_sets)
end
return_tags
end
Expand Down

0 comments on commit f47f088

Please sign in to comment.