Tuesday, July 29, 2025
1 change · saas-18.1
Enhancements to existing features
Website searches now avoid an unnecessary counting step when the existing search results already provide the needed total. This reduces extra database work and can make website, blog, and forum pages load more efficiently without changing what users see.
Original PR description
Issue ----- Currently, we call `model.search()` and `model.search_count()` back-to-back, the second of which is unnecessary if there is no limit on the query. Solution ----- If we have no limit, directly take the length of the previously returned results to avoid an extra query. opw-4882609 Forward-Port-Of: odoo/odoo#220014 Forward-Port-Of: odoo/odoo#218252