[tor-commits] [tor-browser/tor-browser-45.2.0esr-6.0-1] Bug 19411: Update icon shows up even if partial updates are failing.

gk at torproject.org gk at torproject.org
Fri Jun 17 08:06:11 UTC 2016


commit 15792fd075f46d2150a566bd546ec41b427f3588
Author: Kathy Brade <brade at pearlcrescent.com>
Date:   Wed Jun 15 14:12:45 2016 -0400

    Bug 19411: Update icon shows up even if partial updates are failing.
    
    Do not show the "update badge" on the hamburger menu when the update
    state is "downloading" (which means fallback to a complete update is
    in progress).
---
 browser/base/content/browser.js | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/browser/base/content/browser.js b/browser/base/content/browser.js
index 0adbe61..41d72ae 100644
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -2668,6 +2668,12 @@ var gMenuButtonUpdateBadge = {
   },
 
   observe: function (subject, topic, status) {
+    if (status == "downloading") {
+      // A partial update failed and a complete update is being attempted.
+      // Ignore (it does not make sense to show the update badge yet).
+      return;
+    }
+
     if (status == "failed") {
       // Background update has failed, let's show the UI responsible for
       // prompting the user to update manually.



More information about the tor-commits mailing list