1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-02-22 22:15:46 +01:00

[bootstrap] Merge default.

--HG--
branch : bootstrapped
This commit is contained in:
Kris Maglione
2010-12-25 06:58:27 -05:00
4 changed files with 48 additions and 26 deletions

View File

@@ -28,12 +28,7 @@ memoize(this, "Commands", function () {
return obj.Commands;
});
const FailedAssertion = Class("FailedAssertion", Error, {
init: function (message) {
update(this, Error(message))
this.message = message;
}
});
const FailedAssertion = Class("FailedAssertion", ErrorBase);
function wrapCallback(fn)
fn.wrapper = function wrappedCallback () {
@@ -126,7 +121,7 @@ const Util = Module("Util", XPCOM([Ci.nsIObserver, Ci.nsISupportsWeakReference])
*/
assert: function (condition, message) {
if (!condition)
throw FailedAssertion(message);
throw FailedAssertion(message, 1);
},
get chromePackages() {