1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-01-04 18:34:11 +01:00

No arguments in arrow functions yet.

Fix issue #1059.
This commit is contained in:
Doug Kearns
2013-09-17 20:27:23 +10:00
parent 041ad9ace7
commit d8201209c3
2 changed files with 2 additions and 2 deletions

View File

@@ -441,7 +441,7 @@ function curry(fn, length, self, acc) {
return fn;
// Close over function with 'this'
function close(self, fn) () => fn.apply(self, arguments);
function close(self, fn) (...args) => fn.apply(self, args);
if (acc == null)
acc = [];

View File

@@ -747,7 +747,7 @@ var Util = Module("Util", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference]),
httpGet: function httpGet(url, callback, self) {
let params = callback;
if (!isObject(params))
params = { callback: params && (() => callback.apply(self, arguments)) };
params = { callback: params && ((...args) => callback.apply(self, args)) };
try {
let xmlhttp = services.Xmlhttp();