[extensions-web] js: Fix upgrading for certain combinations of extension versions



commit dbd617566e65aaa26decf90e5c95a04af3c2adff
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Tue Jun 26 15:40:14 2012 -0400

    js: Fix upgrading for certain combinations of extension versions
    
      Version 1: 3.4.0
      Version 2: 3.2.0
    
    User installs Version 2, upgrades system, needs to upgrade to 3.4.0.

 sweettooth/static/js/extensions.js |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/sweettooth/static/js/extensions.js b/sweettooth/static/js/extensions.js
index 07eaa38..34daad4 100644
--- a/sweettooth/static/js/extensions.js
+++ b/sweettooth/static/js/extensions.js
@@ -117,7 +117,7 @@ function($, messages, dbusProxy, extensionUtils, templates) {
 
         var svm = meta.shell_version_map || $elem.data('svm');
         var latest = extensionUtils.grabProperExtensionVersion(svm, dbusProxy.ShellVersion);
-        if (latest !== null && latest.version > meta.version)
+        if (latest !== null && (latest.version > meta.version || _state === ExtensionState.OUT_OF_DATE))
             $elem.addClass('upgradable');
 
         function sendPopularity(action) {



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