[REF] website_livechat: adapt code after jQuery update

Part of task 1896658

Co-authored-by: Aaron Bohy <aab@odoo.com>
Co-authored-by: Christophe Matthieu <chm@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: David Monjoie <dmo@odoo.com>
Co-authored-by: Martin Geubelle <mge@odoo.com>
Co-authored-by: svs-odoo <svs@odoo.com>
Co-authored-by: Vincent Schippefilt <vsc@odoo.com>
This commit is contained in:
Vincent Schippefilt
2019-03-06 20:07:17 +01:00
committed by Aaron Bohy
co-authored by Aaron Bohy Christophe Matthieu Mathieu Duckerts-Antoine David Monjoie Martin Geubelle svs-odoo
parent 6928bfb6c7
commit bd88240d3f
@@ -21,14 +21,15 @@ WebsiteNewMenu.include({
* and redirects the user to this new channel.
*
* @private
* @returns {Deferred} Unresolved if there is a redirection
* @returns {Promise} Unresolved if there is a redirection
*/
_createNewChannel: function () {
var self = this;
return wUtils.prompt({
window_title: _t("New Channel"),
input: _t("Name"),
}).then(function (name) {
}).then(function (result) {
var name = result.val;
if (!name) {
return;
}
@@ -41,7 +42,7 @@ WebsiteNewMenu.include({
},
}).then(function (url) {
window.location.href = url;
return $.Deferred();
return new Promise(function () {});
});
});
},