diff options
| author | Vincent Schippefilt <vsc@odoo.com> | 2019-03-06 14:02:01 +0100 |
|---|---|---|
| committer | Aaron Bohy <aab@odoo.com> | 2019-03-06 20:07:17 +0100 |
| commit | 231f9072bf775bd68d5a4fdbfbffa74fc5df0613 (patch) | |
| tree | e2f22577e6c5bfe1f9f0a1fe2100061d1fd9116e /addons/google_drive/static/src/js | |
| parent | a6faca318a5913039dc4f8f1b5cf59bd35786121 (diff) | |
[REF] google_drive: 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>
Diffstat (limited to 'addons/google_drive/static/src/js')
| -rw-r--r-- | addons/google_drive/static/src/js/gdrive.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/addons/google_drive/static/src/js/gdrive.js b/addons/google_drive/static/src/js/gdrive.js index 5855e056161..7ed0487e84d 100644 --- a/addons/google_drive/static/src/js/gdrive.js +++ b/addons/google_drive/static/src/js/gdrive.js @@ -19,7 +19,7 @@ Sidebar.include({ if (this.options.viewType === "form") { def = this._addGoogleDocItems(this.env.model, this.env.activeIds[0]); } - return $.when(def).then(this._super.bind(this)); + return Promise.resolve(def).then(this._super.bind(this)); }, //-------------------------------------------------------------------------- @@ -30,12 +30,12 @@ Sidebar.include({ * @private * @param {string} model * @param {integer} resID - * @returns {Deferred} + * @returns {Promise} */ _addGoogleDocItems: function (model, resID) { var self = this; if (!resID) { - return $.when(); + return Promise.resolve(); } var gdoc_item = _.indexOf(_.pluck(self.items.other, 'classname'), 'oe_share_gdoc'); if (gdoc_item !== -1) { |
