Index: lib/utils.js |
=================================================================== |
--- a/lib/utils.js |
+++ b/lib/utils.js |
@@ -213,21 +213,12 @@ |
/** |
* Posts an action to the event queue of the current thread to run it |
- * asynchronously. Any additional parameters to this function are passed |
- * as parameters to the callback. |
+ * asynchronously. |
* @param {function} callback |
- * @param {object} thisPtr |
*/ |
- runAsync: function(callback, thisPtr) |
+ runAsync: function(callback) |
{ |
- let params = Array.prototype.slice.call(arguments, 2); |
- let runnable = { |
- run: function() |
- { |
- callback.apply(thisPtr, params); |
- } |
- }; |
- Services.tm.currentThread.dispatch(runnable, Ci.nsIEventTarget.DISPATCH_NORMAL); |
+ Services.tm.currentThread.dispatch(callback, Ci.nsIEventTarget.DISPATCH_NORMAL); |
}, |
/** |