log successful ticket delivery, update devDependencies
[squeep-indieauth-helper] / lib / communication.js
index 7a9f6e318f4675a560f0714a0fb7efd1470e4998..2bda4ce2307dc0b026ba3975e65d0f56a936b940 100644 (file)
@@ -62,7 +62,7 @@ class Communication {
         },
         hooks: {
           beforeRetry: [
-            this._onRetry,
+            this._onRetry.bind(this),
           ],
         },
       });
@@ -899,7 +899,9 @@ class Communication {
           ...( issuerUrlObj && { iss: issuerUrlObj.href }),
         },
       };
-      return await this.got(ticketConfig);
+      const result = await this.got(ticketConfig);
+      this.logger.debug(_scope, 'success', { ...common.gotResponseLogData(result) });
+      return result;
     } catch (e) {
       this.logger.error(_scope, 'ticket delivery request failed', { error: e, url: ticketEndpointUrlObj.href });
       throw e;