Skip to content

Open source, privacy-first web analytics. Lightweight, cookie-free Google Analytics alternative. Self-hosted or cloud.

remove Plausible Team footer from self-hosted emails (#3980)

ruslandoga94deb89b9dd2
diff --git a/lib/plausible_web/templates/layout/base_email.html.eex b/lib/plausible_web/templates/layout/base_email.html.eex
index 0679b338ba..f9ffd0af87 100644
--- a/lib/plausible_web/templates/layout/base_email.html.eex
+++ b/lib/plausible_web/templates/layout/base_email.html.eex
@@ -4,12 +4,12 @@
<%= @inner_content %>
<br /><br />
-Regards,<br />
+<%= if full_build?() do %>Regards,<br />
The Plausible Team 💌
-<br /><br />
+<br /><br /><% end %>
--
<br /><br />
<%= link(plausible_url(), to: plausible_url()) %><br />
-{{{ pm:unsubscribe }}}
+<%= if full_build?() do %>{{{ pm:unsubscribe }}}<% end %>
diff --git a/lib/plausible_web/templates/layout/priority_email.html.eex b/lib/plausible_web/templates/layout/priority_email.html.eex
index bddd75b9d7..3ecb07826a 100644
--- a/lib/plausible_web/templates/layout/priority_email.html.eex
+++ b/lib/plausible_web/templates/layout/priority_email.html.eex
@@ -4,9 +4,9 @@
<%= @inner_content %>
<br /><br />
-Regards,<br />
+<%= if full_build?() do %>Regards,<br />
The Plausible Team 💌
-<br /><br />
+<br /><br /><% end %>
--
<br /><br />
diff --git a/test/plausible_web/email_test.exs b/test/plausible_web/email_test.exs
index 9a23e06120..e802127352 100644
--- a/test/plausible_web/email_test.exs
+++ b/test/plausible_web/email_test.exs
@@ -31,6 +31,7 @@ defmodule PlausibleWeb.EmailTest do
assert email.html_body =~ plausible_link()
end
+ @tag :full_build_only
test "renders unsubscribe placeholder" do
email =
Email.base_email()