summaryrefslogtreecommitdiffstats
path: root/application/palemoon/base/content/sanitize.js
diff options
context:
space:
mode:
Diffstat (limited to 'application/palemoon/base/content/sanitize.js')
-rw-r--r--application/palemoon/base/content/sanitize.js17
1 files changed, 12 insertions, 5 deletions
diff --git a/application/palemoon/base/content/sanitize.js b/application/palemoon/base/content/sanitize.js
index fccec6c98..f2eb24a55 100644
--- a/application/palemoon/base/content/sanitize.js
+++ b/application/palemoon/base/content/sanitize.js
@@ -148,7 +148,8 @@ Sanitizer.prototype = {
if (cookie.creationTime > this.range[0])
// This cookie was created after our cutoff, clear it
- cookieMgr.remove(cookie.host, cookie.name, cookie.path, false);
+ cookieMgr.remove(cookie.host, cookie.name, cookie.path,
+ false, cookie.originAttributes);
}
}
else {
@@ -213,10 +214,16 @@ Sanitizer.prototype = {
history: {
clear: function ()
{
- if (this.range)
- PlacesUtils.history.removeVisitsByTimeframe(this.range[0], this.range[1]);
- else
- PlacesUtils.history.removeAllPages();
+ if (this.range) {
+ PlacesUtils.history.removeVisitsByFilter({
+ beginDate: new Date(this.range[0] / 1000),
+ endDate: new Date(this.range[1] / 1000)
+ }).catch(Components.utils.reportError);;
+ } else {
+ // Remove everything.
+ PlacesUtils.history.clear()
+ .catch(Components.utils.reportError);
+ }
try {
var os = Components.classes["@mozilla.org/observer-service;1"]