Bug 1111788 - Part 1 - include timestamps for "browser:purge-session-history" notification. r=gavin a=lmandel
authorJW Wang <jwwang@mozilla.com>
Thu, 08 Jan 2015 18:50:00 +0100
changeset 249044 6195599f25e02afb29a4d57dd8dc2a43920c2c94
parent 249043 c7d212eecc8ea827ff22da89d0ed005204c93256
child 249045 67145bce29be3bc543ab45a44417bc4dfdc64d4f
push id970
push userjryans@gmail.com
push dateTue, 10 Mar 2015 15:54:18 +0000
reviewersgavin, lmandel
bugs1111788
milestone37.0
Bug 1111788 - Part 1 - include timestamps for "browser:purge-session-history" notification. r=gavin a=lmandel
browser/base/content/sanitize.js
--- a/browser/base/content/sanitize.js
+++ b/browser/base/content/sanitize.js
@@ -244,17 +244,18 @@ Sanitizer.prototype = {
         if (this.range)
           PlacesUtils.history.removeVisitsByTimeframe(this.range[0], this.range[1]);
         else
           PlacesUtils.history.removeAllPages();
 
         try {
           var os = Components.classes["@mozilla.org/observer-service;1"]
                              .getService(Components.interfaces.nsIObserverService);
-          os.notifyObservers(null, "browser:purge-session-history", "");
+          let clearStartingTime = this.range ? String(this.range[0]) : "";
+          os.notifyObservers(null, "browser:purge-session-history", clearStartingTime);
         }
         catch (e) { }
 
         try {
           var predictor = Components.classes["@mozilla.org/network/predictor;1"]
                                     .getService(Components.interfaces.nsINetworkPredictor);
           predictor.reset();
         } catch (e) { }