Index: lib/notification.js |
=================================================================== |
--- a/lib/notification.js |
+++ b/lib/notification.js |
@@ -21,14 +21,13 @@ |
* @fileOverview Handles notifications. |
*/ |
-const {Services} = Cu.import("resource://gre/modules/Services.jsm", {}); |
- |
const {Prefs} = require("prefs"); |
const {Downloader, Downloadable, |
MILLIS_IN_MINUTE, MILLIS_IN_HOUR, MILLIS_IN_DAY} = require("downloader"); |
const {Utils} = require("utils"); |
const {Matcher, defaultMatcher} = require("matcher"); |
const {Filter, RegExpFilter, WhitelistFilter} = require("filterClasses"); |
+const {compareVersion} = require("coreUtils"); |
const INITIAL_DELAY = 1 * MILLIS_IN_MINUTE; |
const CHECK_INTERVAL = 1 * MILLIS_IN_HOUR; |
@@ -217,19 +216,19 @@ |
let targetChecks = { |
extension: v => v == addonName, |
extensionMinVersion: |
- v => Services.vc.compare(addonVersion, v) >= 0, |
+ v => compareVersion(addonVersion, v) >= 0, |
extensionMaxVersion: |
- v => Services.vc.compare(addonVersion, v) <= 0, |
+ v => compareVersion(addonVersion, v) <= 0, |
application: v => v == application, |
applicationMinVersion: |
- v => Services.vc.compare(applicationVersion, v) >= 0, |
+ v => compareVersion(applicationVersion, v) >= 0, |
applicationMaxVersion: |
- v => Services.vc.compare(applicationVersion, v) <= 0, |
+ v => compareVersion(applicationVersion, v) <= 0, |
platform: v => v == platform, |
platformMinVersion: |
- v => Services.vc.compare(platformVersion, v) >= 0, |
+ v => compareVersion(platformVersion, v) >= 0, |
platformMaxVersion: |
- v => Services.vc.compare(platformVersion, v) <= 0, |
+ v => compareVersion(platformVersion, v) <= 0, |
blockedTotalMin: v => Prefs.show_statsinpopup && |
Prefs.blocked_total >= v, |
blockedTotalMax: v => Prefs.show_statsinpopup && |