From ec59d0e9a9b583f86b2adb523581e04b6749680b Mon Sep 17 00:00:00 2001
From: Paul <paulmakles@gmail.com>
Date: Tue, 27 Jul 2021 16:16:17 +0100
Subject: [PATCH] Try to make email not go into spam.

---
 assets/templates/reset.html  | 90 +++++++++++++++++++-----------------
 assets/templates/verify.html | 90 +++++++++++++++++++-----------------
 set_version.sh               |  2 +-
 src/main.rs                  |  8 ++--
 src/version.rs               |  2 +-
 5 files changed, 100 insertions(+), 92 deletions(-)

diff --git a/assets/templates/reset.html b/assets/templates/reset.html
index 5157f09..6f844fb 100644
--- a/assets/templates/reset.html
+++ b/assets/templates/reset.html
@@ -4,57 +4,61 @@
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
 	<title>Reset your password.</title>
 	<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
-
+	
 	<style type="text/css">
 		a[x-apple-data-detectors] {color: inherit !important;}
 	</style>
-
+	
 </head>
 <body style="margin: 0; padding: 0;">
 	<table role="presentation" border="0" cellpadding="0" cellspacing="0" width="100%">
 		<tr>
 			<td style="padding: 20px 0 30px 0;">
-
-<table align="center" border="0" cellpadding="0" cellspacing="0" width="600" style="border-collapse: collapse; border: 1px solid #cccccc;">
-	<tr>
-		<td align="center" bgcolor="#ff4654">
-			<img src="https://revolt.chat/header.png" alt="REVOLT logo" width="600" height="168" style="display: block;" />
-		</td>
-	</tr>
-	<tr>
-		<td bgcolor="#ffffff" style="padding: 40px 30px 40px 30px;">
-			<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
-				<tr>
-					<td style="color: #153643; font-family: Arial, sans-serif;">
-						<h1 style="font-size: 24px; margin: 0;">Reset your password!</h1>
-					</td>
-				</tr>
-				<tr>
-					<td style="color: #153643; font-family: Arial, sans-serif; font-size: 16px; line-height: 24px; padding: 20px 0 0 0;">
-						<p style="margin: 0;">
-              Reset your password by <a href="{{url}}">clicking here</a>.
-            </p>
-            <p>
-              Or by manually navigating to the URL: {{url}}
-            </p>
-					</td>
-				</tr>
-			</table>
-		</td>
-	</tr>
-	<tr>
-		<td bgcolor="#ff4654" style="padding: 30px 30px;">
-    		<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
-				<tr>
-					<td style="color: #ffffff; font-family: Arial, sans-serif; font-size: 14px;">
-            <p style="margin: 0;">Sent by REVOLT. &middot; <a style="color: white;" href="https://revolt.chat">Website</a> &middot; <a style="color: white;" href="https://gitlab.insrt.uk/revolt">Source Code</a></p>
-					</td>
-				</tr>
-			</table>
-		</td>
-	</tr>
-</table>
-
+				
+				<table align="center" border="0" cellpadding="0" cellspacing="0" width="600" style="border-collapse: collapse; border: 1px solid #cccccc;">
+					<tr>
+						<td align="center" bgcolor="#ff4654">
+							<img src="https://revolt.chat/header.png" alt="Revolt logo" width="600" height="168" style="display: block;" />
+						</td>
+					</tr>
+					<tr>
+						<td bgcolor="#ffffff" style="padding: 40px 30px 40px 30px;">
+							<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
+								<tr>
+									<td style="color: #153643; font-family: Arial, sans-serif;">
+										<h1 style="font-size: 24px; margin: 0;">Reset your password!</h1>
+									</td>
+								</tr>
+								<tr>
+									<td style="color: #153643; font-family: Arial, sans-serif; font-size: 16px; line-height: 24px; padding: 20px 0 0 0;">
+										<p>
+											You requested a password reset, if you did not request this then you can safely ignore it.
+										</p>
+										<p style="margin: 0;">
+											Reset your password by <a href="{{url}}">clicking here</a>.
+										</p>
+										<p>
+											Or by manually navigating to the URL: {{url}}
+										</p>
+									</td>
+								</tr>
+							</table>
+						</td>
+					</tr>
+					<tr>
+						<td bgcolor="#ff4654" style="padding: 30px 30px;">
+							<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
+								<tr>
+									<td style="color: #ffffff; font-family: Arial, sans-serif; font-size: 14px;">
+										<p style="margin: 0;">Sent by Revolt. &middot; <a style="color: white;" href="https://revolt.chat">Website</a></p>
+										<p>Revolt is a user-first chat platform built with modern web technologies.</p>
+									</td>
+								</tr>
+							</table>
+						</td>
+					</tr>
+				</table>
+				
 			</td>
 		</tr>
 	</table>
diff --git a/assets/templates/verify.html b/assets/templates/verify.html
index c02ea6e..28ed90e 100644
--- a/assets/templates/verify.html
+++ b/assets/templates/verify.html
@@ -4,57 +4,61 @@
 	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
 	<title>Verify your account.</title>
 	<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
-
+	
 	<style type="text/css">
 		a[x-apple-data-detectors] {color: inherit !important;}
 	</style>
-
+	
 </head>
 <body style="margin: 0; padding: 0;">
 	<table role="presentation" border="0" cellpadding="0" cellspacing="0" width="100%">
 		<tr>
 			<td style="padding: 20px 0 30px 0;">
-
-<table align="center" border="0" cellpadding="0" cellspacing="0" width="600" style="border-collapse: collapse; border: 1px solid #cccccc;">
-	<tr>
-		<td align="center" bgcolor="#ff4654">
-			<img src="https://revolt.chat/header.png" alt="REVOLT logo" width="600" height="168" style="display: block;" />
-		</td>
-	</tr>
-	<tr>
-		<td bgcolor="#ffffff" style="padding: 40px 30px 40px 30px;">
-			<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
-				<tr>
-					<td style="color: #153643; font-family: Arial, sans-serif;">
-						<h1 style="font-size: 24px; margin: 0;">Verify your account!</h1>
-					</td>
-				</tr>
-				<tr>
-					<td style="color: #153643; font-family: Arial, sans-serif; font-size: 16px; line-height: 24px; padding: 20px 0 0 0;">
-						<p style="margin: 0;">
-              Please verify your account by <a href="{{url}}">clicking here</a>.
-            </p>
-            <p>
-              Or by manually navigating to the URL: {{url}}
-            </p>
-					</td>
-				</tr>
-			</table>
-		</td>
-	</tr>
-	<tr>
-		<td bgcolor="#ff4654" style="padding: 30px 30px;">
-    		<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
-				<tr>
-					<td style="color: #ffffff; font-family: Arial, sans-serif; font-size: 14px;">
-            <p style="margin: 0;">Sent by REVOLT. &middot; <a style="color: white;" href="https://revolt.chat">Website</a> &middot; <a style="color: white;" href="https://gitlab.insrt.uk/revolt">Source Code</a></p>
-					</td>
-				</tr>
-			</table>
-		</td>
-	</tr>
-</table>
-
+				
+				<table align="center" border="0" cellpadding="0" cellspacing="0" width="600" style="border-collapse: collapse; border: 1px solid #cccccc;">
+					<tr>
+						<td align="center" bgcolor="#ff4654">
+							<img src="https://revolt.chat/header.png" alt="Revolt logo" width="600" height="168" style="display: block;" />
+						</td>
+					</tr>
+					<tr>
+						<td bgcolor="#ffffff" style="padding: 40px 30px 40px 30px;">
+							<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
+								<tr>
+									<td style="color: #153643; font-family: Arial, sans-serif;">
+										<h1 style="font-size: 24px; margin: 0;">Verify your account!</h1>
+									</td>
+								</tr>
+								<tr>
+									<td style="color: #153643; font-family: Arial, sans-serif; font-size: 16px; line-height: 24px; padding: 20px 0 0 0;">
+										<p>
+											You're almost there! Verify your account to be able to log into the platform.
+										</p>
+										<p style="margin: 0;">
+											Please verify your account by <a href="{{url}}">clicking here</a>.
+										</p>
+										<p>
+											Or by manually navigating to the URL: {{url}}
+										</p>
+									</td>
+								</tr>
+							</table>
+						</td>
+					</tr>
+					<tr>
+						<td bgcolor="#ff4654" style="padding: 30px 30px;">
+							<table border="0" cellpadding="0" cellspacing="0" width="100%" style="border-collapse: collapse;">
+								<tr>
+									<td style="color: #ffffff; font-family: Arial, sans-serif; font-size: 14px;">
+										<p style="margin: 0;">Sent by Revolt. &middot; <a style="color: white;" href="https://revolt.chat">Website</a></p>
+										<p>Revolt is a user-first chat platform built with modern web technologies.</p>
+									</td>
+								</tr>
+							</table>
+						</td>
+					</tr>
+				</table>
+				
 			</td>
 		</tr>
 	</table>
diff --git a/set_version.sh b/set_version.sh
index 7c32c4e..a8e1c49 100755
--- a/set_version.sh
+++ b/set_version.sh
@@ -1,3 +1,3 @@
 #!/bin/bash
-export version=0.5.1-alpha.11-patch.0
+export version=0.5.1-alpha.12
 echo "pub const VERSION: &str = \"${version}\";" > src/version.rs
diff --git a/src/main.rs b/src/main.rs
index fdbe4df..8f25d47 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -86,13 +86,13 @@ async fn launch_web() {
 
                 templates: Templates {
                     verify_email: Template {
-                        title: "Verify your REVOLT account.",
-                        text: "Verify your email here: {{url}}",
+                        title: "Verify your Revolt account.",
+                        text: "You're almost there! Verify your account to be able to log into the platform.\nPlease verify your account here: {{url}}\n\nSent by Revolt. · Website: https://revolt.chat\nRevolt is a user-first chat platform built with modern web technologies.",
                         html: include_str!("../assets/templates/verify.html"),
                     },
                     reset_password: Template {
-                        title: "Reset your REVOLT password.",
-                        text: "Reset your password here: {{url}}",
+                        title: "Reset your Revolt password.",
+                        text: "You requested a password reset, if you did not request this then you can safely ignore it.\nReset your password here: {{url}}\n\nSent by Revolt. · Website: https://revolt.chat\nRevolt is a user-first chat platform built with modern web technologies.",
                         html: include_str!("../assets/templates/reset.html"),
                     },
                     welcome: None,
diff --git a/src/version.rs b/src/version.rs
index 1ee83eb..5004496 100644
--- a/src/version.rs
+++ b/src/version.rs
@@ -1 +1 @@
-pub const VERSION: &str = "0.5.1-alpha.11-patch.0";
+pub const VERSION: &str = "0.5.1-alpha.12";
-- 
GitLab