diff --git a/app/views/users/mailer/notification.html.erb b/app/views/users/mailer/notification.html.erb index 6262a788c..526e57b44 100644 --- a/app/views/users/mailer/notification.html.erb +++ b/app/views/users/mailer/notification.html.erb @@ -21,7 +21,7 @@ <% if @notification.system_message? %> <% # We assume the system notification is clean %> <%= @notification.message.html_safe %> - <% elsif @notification.deliver? %> + <% elsif @notification.deliver? && @notification.message.match?(/data-id=('|")(\d*)('|")/) %> <%= I18n.t("notifications.deliver.download_link") %> <% # work around the problem with inserting the link of zipExport %> <% zip_id = /data-id=('|")(\d*)('|")/.match(@notification.message)[2] %>