From d5b12fa7f98525a416b34cdf42d79b29c0879fe4 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Mon, 22 Mar 2021 19:23:01 +0100 Subject: [PATCH] log endpoint hostname --- src/matrix/push/Pusher.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/matrix/push/Pusher.js b/src/matrix/push/Pusher.js index a8ac1b21..e12db164 100644 --- a/src/matrix/push/Pusher.js +++ b/src/matrix/push/Pusher.js @@ -21,6 +21,12 @@ export class Pusher { } async enable(hsApi, log) { + try { + let endpointDomain = new URL(this._description.data.endpoint).host; + log.set("endpoint", endpointDomain); + } catch { + log.set("endpoint", null); + } await hsApi.setPusher(this._description, {log}).response(); }