dump JSON.stringified error on HAWK.signCertificate error
authorMark Hammond <mhammond@skippinet.com.au>
Thu, 19 Dec 2013 16:38:35 +1100
changeset 161534 31f9d496d6171d79dce915d04ea663bc09078f67
parent 161533 9039f1de78296d97259c3c088b13dcebba2d7148
child 161535 f3ff4bbaa1a5f9ceee692fdcda27e9b559f1dbab
push id4124
push userkwierso@gmail.com
push dateSat, 21 Dec 2013 03:02:52 +0000
treeherderfx-team@f644da1c9331 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
milestone29.0a1
dump JSON.stringified error on HAWK.signCertificate error
services/fxaccounts/FxAccountsClient.jsm
--- a/services/fxaccounts/FxAccountsClient.jsm
+++ b/services/fxaccounts/FxAccountsClient.jsm
@@ -182,17 +182,17 @@ this.FxAccountsClient.prototype = {
   signCertificate: function (sessionTokenHex, serializedPublicKey, lifetime) {
     let creds = this._deriveHawkCredentials(sessionTokenHex, "sessionToken");
 
     let body = { publicKey: serializedPublicKey,
                  duration: lifetime };
     return Promise.resolve()
       .then(_ => this._request("/certificate/sign", "POST", creds, body))
       .then(resp => resp.cert,
-            err => {dump("HAWK.signCertificate error: " + err + "\n");
+            err => {dump("HAWK.signCertificate error: " + JSON.stringify(err) + "\n");
                     throw err;});
   },
 
   /**
    * Determine if an account exists
    *
    * @param email
    *        The email address to check