From 634e4e951ac88b38d23115705b1e2dee1a06f1d3 Mon Sep 17 00:00:00 2001 From: Timo Sand Date: Thu, 7 Mar 2013 12:57:55 +0000 Subject: Replaces workaround and should let travis work again --- lib/utils.coffee | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'lib') diff --git a/lib/utils.coffee b/lib/utils.coffee index 9e15dcc0..f089f89d 100644 --- a/lib/utils.coffee +++ b/lib/utils.coffee @@ -1,10 +1,8 @@ Utils = getCurrentVersion: -> - # Chromium #15242 will make this XHR request to access the manifest unnecessary - manifestRequest = new XMLHttpRequest() - manifestRequest.open("GET", chrome.extension.getURL("manifest.json"), false) - manifestRequest.send(null) - JSON.parse(manifestRequest.responseText).version + chrome.management.get(chrome.i18n.getMessage('@@extension_id'), (info) -> + info.version + ) # Takes a dot-notation object string and call the function # that it points to with the correct value for 'this'. @@ -136,7 +134,7 @@ Utils = # locale-sensitive uppercase detection hasUpperCase: (s) -> s.toLowerCase() != s - + # This creates a new function out of an existing function, where the new function takes fewer arguments. This # allows us to pass around functions instead of functions + a partial list of arguments. Function::curry = -> -- cgit v1.2.3