From 044b2b2c379738c828089cda7afd0ebe8ce63c1c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20=C3=89vrard?= Date: Thu, 13 Feb 2025 18:35:32 +0100 Subject: [PATCH] Handle errors when processing wizard steps Closes #13906 (grafted from ab4ac9e315c67207a0855e4314689260ab0b59ba) --HG-- branch : 6.0 --- sao/src/rpc.js | 4 +++- sao/src/wizard.js | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/sao/src/rpc.js b/sao/src/rpc.js index 8860a247a9..e45ef8be80 100644 --- a/sao/src/rpc.js +++ b/sao/src/rpc.js @@ -97,7 +97,9 @@ } } else { Sao.common.error.run(data.error[0], data.error[1]) - .always(dfd.reject); + .always(function() { + dfd.reject(data.error); + }); } } else { result = data.result; diff --git a/sao/src/wizard.js b/sao/src/wizard.js index 9b2010eefc..fb2d38d6cb 100644 --- a/sao/src/wizard.js +++ b/sao/src/wizard.js @@ -106,7 +106,10 @@ } this.__processing = false; }.bind(this), function(result) { - // TODO end for server error. + if (!result || !this.screen) { + this.state = this.end_state; + this.end(); + } this.__processing = false; }.bind(this)); };