aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2023-12-07 23:08:32 -0800
committerAdam Soltys <[email protected]>2023-12-07 23:08:32 -0800
commit17cf1c5dc76c1c566a34f3e687c3b5e3ef423862 (patch)
tree3baa5ca8786e21af1768d8eb7dd1e5f4faa621a1 /lib
parent602f509706493585e35ed0cdce3e47debd312445 (diff)
downloadcoinos-server-17cf1c5dc76c1c566a34f3e687c3b5e3ef423862.tar.gz
coinos-server-17cf1c5dc76c1c566a34f3e687c3b5e3ef423862.zip
notify flag
Diffstat (limited to 'lib')
-rw-r--r--lib/payments.js4
-rw-r--r--lib/whitelist.js1
2 files changed, 3 insertions, 2 deletions
diff --git a/lib/payments.js b/lib/payments.js
index 2220395a..14bdf7ae 100644
--- a/lib/payments.js
+++ b/lib/payments.js
@@ -182,7 +182,7 @@ export let credit = async (hash, amount, memo, ref, type = types.internal) => {
notify(user, `Received ${amount} sats`);
callWebhook(invoice, p);
- if (user.verified) {
+ if (user.verified && user.notify) {
mail(user, "Payment received", templates.paymentReceived, {
username,
sats:
@@ -191,7 +191,7 @@ export let credit = async (hash, amount, memo, ref, type = types.internal) => {
p.amount
),
link: `${process.env.URL}/payment/${p.id}`
- });
+ });
}
mqtt1.publish(
diff --git a/lib/whitelist.js b/lib/whitelist.js
index 8c988ab5..a1a48223 100644
--- a/lib/whitelist.js
+++ b/lib/whitelist.js
@@ -1,4 +1,5 @@
export default [
+ "notify",
"anon",
"balance",
"address",