Files
odoo_source/addons/web/static/tests/core
Aaron Bohy 23e93f9341 [FIX] web: Mutex: do not fork rejected promise
Have a many2one field in a form view, and try to quick create a
record. If the name_create returns an error (e.g. ValidationError
in the model), the many2one field opens a form in a dialog (aka the
slow create). It thus properly handle the error.

However, before this commit, the error returned by the RPC was also
displayed in its own dialog (behind the form dialog).

This was due to a mistake in the Mutex, which forks the promise
returned by the registered action. When that promise was rejected,
the forked one was thus rejected as well, and it wasn't caught.
That later promise is only used to unlock the mutex, so we can
safely catch it.

closes odoo/odoo#101549

X-original-commit: fe9e044b9e03ac7fff5d314e6e207921a15c8965
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-09-29 12:17:09 +02:00
..
2022-08-31 18:53:51 +02:00
2022-08-31 18:53:51 +02:00
2022-08-31 18:53:51 +02:00
2022-08-31 18:53:51 +02:00
2022-08-31 18:53:51 +02:00
2022-08-31 18:53:51 +02:00