Open source, privacy-first web analytics. Lightweight, cookie-free Google Analytics alternative. Self-hosted or cloud.
TypeScript analyticsanalytics-dashboardclickhouseelixirgoogle-analyticsmarketingopen-source-analyticsphoenixplausible-analyticspostgresqlprivacyprivacy-friendlyself-hostedsimple-analyticsstatisticstailwindcssweb-analyticswebsite-analyticswebsite-statswebsite-tracking
Add ability to resend activation codes
Uku Taht1a87013514b0
diff --git a/lib/plausible_web/controllers/auth_controller.ex b/lib/plausible_web/controllers/auth_controller.exindex 2408c6224b..5cb5bb0fb8 100644--- a/lib/plausible_web/controllers/auth_controller.ex+++ b/lib/plausible_web/controllers/auth_controller.ex@@ -90,9 +90,9 @@ defmodule PlausibleWeb.AuthController dodef request_activation_code(conn, _params) douser = conn.assigns[:current_user]- pin = Auth.issue_email_verification(user)+ code = Auth.issue_email_verification(user)- email_template = PlausibleWeb.Email.activation_email(user, pin)+ email_template = PlausibleWeb.Email.activation_email(user, code)Plausible.Mailer.send_email(email_template)conndiff --git a/lib/plausible_web/templates/auth/activate.html.eex b/lib/plausible_web/templates/auth/activate.html.eexindex 933bfb0e4b..806ab6f910 100644--- a/lib/plausible_web/templates/auth/activate.html.eex+++ b/lib/plausible_web/templates/auth/activate.html.eex@@ -18,9 +18,11 @@<div class="mt-16 text-sm dark:text-gray-100">Didn't receive an email?</div>- <div class="mt-2 text-sm text-gray-500 leading-tight">- Please check your spam folder and contact <a class="underline text-indigo-500" href="mailto:[email protected]">[email protected]</a> if the problem persists- </div>+ <ol class="list-decimal text-xs text-gray-500 leading-tight space-y-1 mt-1">+ <li>Check your spam folder</li>+ <li><%= link("Send a new code", class: "underline text-indigo-600", to: "/activate/request-code", method: :post) %> to <%= @conn.assigns[:current_user].email %></li>+ <li>Contact <a class="underline text-indigo-600" href="mailto:[email protected]">[email protected]</a> if the problem persists</li>+ </ol><% end %><% else %><div class="w-full max-w-lg mx-auto bg-white dark:bg-gray-800 shadow-md rounded px-8 py-6 mb-4 mt-8">