[Pkg-mozext-commits] [tabmixplus] 32/107: TypeError: 'toString' called on an object that does not implement interface Exception. When error is instanceof Components.Exception

David Prévot taffit at moszumanska.debian.org
Tue Dec 29 19:02:47 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository tabmixplus.

commit 6b8a9cc65d2517ba04ba53c7a44f8ae6baa2db1c
Author: onemen <tabmix.onemen at gmail.com>
Date:   Mon Oct 26 18:06:26 2015 +0200

    TypeError: 'toString' called on an object that does not implement interface Exception. When error is instanceof Components.Exception
---
 modules/log.jsm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/modules/log.jsm b/modules/log.jsm
index 0b2e486..f1ade61 100644
--- a/modules/log.jsm
+++ b/modules/log.jsm
@@ -275,7 +275,9 @@ options = {
       this.trace(msg + (aError || ""), "errorFlag", this.caller);
       return;
     }
-    if (/Error/.test(Object.getPrototypeOf(aError))) {
+    if (typeof aError == "object" &&
+        (aError instanceof Components.Exception ||
+         aError instanceof Error)) {
       this.reportError(aError, aMsg);
     }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/tabmixplus.git



More information about the Pkg-mozext-commits mailing list