Skip to content

Commit

Permalink
Fix Maximum number of Iterations Exceeded when no catalogs set for AT…
Browse files Browse the repository at this point in the history
… type (#2422)

* Return list if catalog is not found instead of None

* Changelog

* Changelog
  • Loading branch information
Lunga001 authored Nov 14, 2023
1 parent 3db39dd commit d2f3993
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ Changelog
2.5.0 (unreleased)
------------------

- #2422 Fix Maximum number of Iterations Exceeded when no catalogs set for AT type
- #2421 Fix hanging sampletype listing view in setup
- #2420 Fix page reload in multi results classic view
- #2419 Check permission when automatic sample reception is enabled
Expand Down
2 changes: 1 addition & 1 deletion src/bika/lims/api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1135,7 +1135,7 @@ def get_catalogs_for(brain_or_object, default=PORTAL_CATALOG):
# AT content type
# => Looup via archetype_tool
archetype_tool = get_tool("archetype_tool")
catalogs = archetype_tool.catalog_map.get(portal_type)
catalogs = archetype_tool.catalog_map.get(portal_type) or []
else:
# DX content type
# => resolve the `_catalogs` attribute from the class
Expand Down

0 comments on commit d2f3993

Please sign in to comment.