Issue
-----
The cache is not updated properly when the configuration of a currency changes.
This leads to reading stale values in other places. For instance, changing currency
symbol position isn't reflected in invoice tree views unless after a server restart.
Steps
-----
- Open Accounting -> Configuration -> Currencies.
- Pick the active currency, say USD.
- Change 'Currency Symbol Position' to a different value.
- Go to Accounting -> Customers -> Invoices. The displayed amounts don't reflect
the change.
Cause
-----
Cache refresh was misplaced after a premature return, so the cache wasn't refreshed
when 'digits', 'position' or 'symbol' fields of `res.currency` are written, although
that was the intent.
opw-3849155
closesodoo/odoo#161036
Signed-off-by: Moataz Hussein (mohu) <mohu@odoo.com>