[extensions-web] extensions: try to disable system extension prior to upgrade.



commit ec57076413fce9e435a028887f551b2efdff94ab
Author: Yuri Konotopov <ykonotopov gnome org>
Date:   Sun Feb 12 12:46:22 2017 +0400

    extensions: try to disable system extension prior to upgrade.
    
    Otherwise it may be loaded twice as I see.

 sweettooth/static/js/extensions.js |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/sweettooth/static/js/extensions.js b/sweettooth/static/js/extensions.js
index 3ee058a..ced3b00 100644
--- a/sweettooth/static/js/extensions.js
+++ b/sweettooth/static/js/extensions.js
@@ -154,7 +154,13 @@ define(['jquery', 'messages', 'dbus!_', 'extensionUtils', 'templates', 'paginato
                                }
                                else
                                {
-                                       installExtension();
+                                       dbusProxy.DisableExtension(uuid).then(function (result) {
+                                               // Install extension if we were able to disable it first
+                                               if(result)
+                                               {
+                                                       installExtension();
+                                               }
+                                       });
                                }
                        });
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]