-
- Downloads
[IMP] website, test_website: avoid a query on res_company_user_rel
Manual forward port, commit was lost from 15.2 to master. Either it seemed not needed after the httpocalypse refactoring, or was simply lost during the rebase. ----- We can remove an useless SQL Query for public user on every single page serve, if we directly set the website's company_id in the available company_ids of the public user. Indeed, the public user from a website always have the same company_id as the website. We can then do that directly and bypass the next line which will always be true in the case of the public user, making a read for nothing. task-2774979 closes #85419 X-original-commit: c95ab6f2 [1]: https://github.com/odoo/odoo/commit/728ade674cb12c64718efda56b0d5d542e319cba closes odoo/odoo#87856 Signed-off-by:Romain Derie (rde) <rde@odoo.com>
Showing
- addons/test_website/tests/test_performance.py 2 additions, 2 deletionsaddons/test_website/tests/test_performance.py
- addons/website/models/ir_http.py 10 additions, 4 deletionsaddons/website/models/ir_http.py
- addons/website/tests/test_performance.py 7 additions, 7 deletionsaddons/website/tests/test_performance.py
Please register or sign in to comment