From 99d9b401a2f415a751ca8ba9c2e2647d120fa4b1 Mon Sep 17 00:00:00 2001
From: SilicaAndPina <earsyum@gmail.com>
Date: Thu, 13 May 2021 20:39:19 +1200
Subject: [PATCH] Improve email validation (still not rfc compliant tbh)

---
 WebInterface/master-site/web/newuser.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/WebInterface/master-site/web/newuser.php b/WebInterface/master-site/web/newuser.php
index 21a8c3e..5031e07 100755
--- a/WebInterface/master-site/web/newuser.php
+++ b/WebInterface/master-site/web/newuser.php
@@ -104,7 +104,7 @@ if(isset( $_POST['user'],$_POST['pass1'],$_POST['pass2'],$_POST['sex'],$_POST['e
 		array_push($problems, "The password cannot have the username within it!.");
 	
 	
-	if(!preg_match('/^[A-Za-z0-9]*\@[A-Za-z0-9]*\.[A-Za-z0-9]{1,4}$/',$email))
+	if(!preg_match('/^[A-Za-z0-9_.+-]*\@[A-Za-z0-9_.+-]*\.[A-Za-z0-9_.+-]{1,4}$/',$email))
 		array_push($problems, "Email does not appear valid, you will not be able sign in without getting the login mail.");