aboutsummaryrefslogtreecommitdiffstats
path: root/nwcpush/server.js
diff options
context:
space:
mode:
Diffstat (limited to 'nwcpush/server.js')
-rw-r--r--nwcpush/server.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/nwcpush/server.js b/nwcpush/server.js
index 198757c..947b52e 100644
--- a/nwcpush/server.js
+++ b/nwcpush/server.js
@@ -213,8 +213,10 @@ function onNotifyEvent(ev) {
if (ev.kind === CALL_WRAP) {
if (!p || String(ev.content || '').length < CALL_OFFER_MIN) return;
keepCallWrap(ev);
+ // only to an app that says it rings for calls (reasons.call): an older
+ // one's worker has no words for a call and would call it chat
for (const [id, r] of Object.entries(notifyRegs)) {
- if ((r.ptags || []).includes(p)) pushNotify(id, r, 'call', { wrapId: ev.id }).catch(() => {});
+ if (r.reasons?.call === true && (r.ptags || []).includes(p)) pushNotify(id, r, 'call', { wrapId: ev.id }).catch(() => {});
}
return;
}