Improve approaching accept_traffic_until e-mail (#3660)

* Improve approaching accept_traffic_until e-mail

* fixup

* format
This commit is contained in:
hq1 2024-01-02 13:18:51 +01:00 committed by GitHub
parent 75a7ef5241
commit 73923404b0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 6 deletions

View File

@ -358,7 +358,7 @@ defmodule PlausibleWeb.Email do
|> to(user.email)
|> tag("drop-traffic-warning-first")
|> subject("We'll stop counting your stats")
|> render("approaching_accept_traffic_until.html", time: "next week")
|> render("approaching_accept_traffic_until.html", time: "next week", user: user)
end
def approaching_accept_traffic_until_tomorrow(user) do

View File

@ -1,8 +1,7 @@
You used to have an active account with Plausible Analytics, a simple, lightweight, open source and privacy-first Google Analytics alternative.
<br /><br />
We've noticed that you're still sending us stats so we're writing to inform you that we'll stop accepting stats from your sites <%= @time %>. We're an independent, bootstrapped service and we don't sell your data, so this will reduce our server costs and help keep us sustainable.
If you'd like to continue counting your site stats in a privacy-friendly way, please
<br /><br /> If you'd like to continue counting your site stats in a privacy-friendly way, please
<a href={plausible_url()}>login to your Plausible account</a> and start a subscription.
<br /><br />
Do you have any questions or need help with anything? Just reply to this email and we'll gladly help.

View File

@ -247,13 +247,14 @@ defmodule PlausibleWeb.EmailTest do
describe "approaching accept_traffic_until" do
test "renders first warning" do
user = build(:user)
user = build(:user, name: "John Doe")
%{html_body: body, subject: subject} =
PlausibleWeb.Email.approaching_accept_traffic_until(user)
assert subject == "We'll stop counting your stats"
assert body =~ plausible_link()
assert body =~ "Hey John,"
assert body =~
"We've noticed that you're still sending us stats so we're writing to inform you that we'll stop accepting stats from your sites next week."