mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-02-22 07:35:45 +01:00
Better handling of operations on list options with complex types. Closes #37.
This commit is contained in:
@@ -83,6 +83,13 @@ var Promises = Module("Promises", {
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns true if the passed object is a promise.
|
||||
*/
|
||||
isPromise: function isPromise(obj) {
|
||||
return isObject(obj) && typeof obj.then === "function";
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns a promise which resolves after the given number of
|
||||
* milliseconds.
|
||||
|
||||
Reference in New Issue
Block a user