Skip to content
Snippets Groups Projects
Commit 344614b5 authored by Sébastien Theys's avatar Sébastien Theys
Browse files

[IMP] base, product: optimize image compute when image is not set


All of those fields `__get__` and method calls have a cost, it is small but when
done for many records it adds up, so they are better not done.

When creating 1000 products without image, this compute takes:

47ms +/- 1ms before the commit
37ms +/- 1ms after the commit

That's around 20% less.

Part of task-1918881

closes odoo/odoo#34294

Signed-off-by: default avatarJérémy Kersten (jke) <jke@openerp.com>
parent 9150c3d2
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment