diff --git a/install/data/defaults.json b/install/data/defaults.json
index d8ae3a488f..05b16670cc 100644
--- a/install/data/defaults.json
+++ b/install/data/defaults.json
@@ -123,6 +123,7 @@
"maximumRelatedTopics": 0,
"disableEmailSubscriptions": 0,
"emailConfirmInterval": 10,
+ "removeEmailNotificationImages": 0,
"inviteExpiration": 7,
"digestHour": 17,
"passwordExpiryDays": 0,
diff --git a/public/language/en-GB/admin/settings/email.json b/public/language/en-GB/admin/settings/email.json
index f6ade9cfc9..839fd2b6f6 100644
--- a/public/language/en-GB/admin/settings/email.json
+++ b/public/language/en-GB/admin/settings/email.json
@@ -4,7 +4,7 @@
"address-help": "The following email address refers to the email that the recipient will see in the \"From\" and \"Reply To\" fields.",
"from": "From Name",
"from-help": "The from name to display in the email.",
-
+
"smtp-transport": "SMTP Transport",
"smtp-transport.enabled": "Use an external email server to send emails",
"smtp-transport-help": "You can select from a list of well-known services or enter a custom one.",
@@ -35,5 +35,7 @@
"subscriptions": "Email Digests",
"subscriptions.disable": "Disable email digests",
"subscriptions.hour": "Digest Hour",
- "subscriptions.hour-help": "Please enter a number representing the hour to send scheduled email digests (e.g. 0
for midnight, 17
for 5:00pm). Keep in mind that this is the hour according to the server itself, and may not exactly match your system clock.
The approximate server time is:
The next daily digest is scheduled to be sent "
+ "subscriptions.hour-help": "Please enter a number representing the hour to send scheduled email digests (e.g. 0
for midnight, 17
for 5:00pm). Keep in mind that this is the hour according to the server itself, and may not exactly match your system clock.
The approximate server time is:
The next daily digest is scheduled to be sent ",
+ "notifications.settings": "Email notification settings",
+ "notifications.remove-images": "Remove images from email notifications"
}
\ No newline at end of file
diff --git a/src/notifications.js b/src/notifications.js
index d92aa71e8f..72e6e7ee07 100644
--- a/src/notifications.js
+++ b/src/notifications.js
@@ -175,6 +175,9 @@ async function pushToUids(uids, notification) {
notification['cta-type'] = notification.type;
}
let body = notification.bodyLong || '';
+ if (meta.config.removeEmailNotificationImages) {
+ body = body.replace(/]*>/, '');
+ }
body = posts.relativeToAbsolute(body, posts.urlRegex);
body = posts.relativeToAbsolute(body, posts.imgRegex);
await async.eachLimit(uids, 3, function (uid, next) {
diff --git a/src/views/admin/settings/email.tpl b/src/views/admin/settings/email.tpl
index df1d2ce84d..3e54b08e1f 100644
--- a/src/views/admin/settings/email.tpl
+++ b/src/views/admin/settings/email.tpl
@@ -154,4 +154,18 @@
+