actually start on mailing, fix email regex
Some checks failed
Code quality checks / biome (push) Failing after 22s

This commit is contained in:
creations 2025-06-10 16:34:15 -04:00
parent 00a7417936
commit 86be889ede
Signed by: creations
GPG key ID: 8F553AA4320FC711
17 changed files with 349 additions and 32 deletions

View file

@ -1,3 +1,4 @@
export * from "./server";
export * from "./validation";
export * from "./database";
export * from "./mailer";

View file

@ -0,0 +1,8 @@
import { resolve } from "node:path";
export const templatesPath = resolve(
"src",
"environment",
"mailer",
"templates",
);

View file

@ -14,7 +14,7 @@ const forbiddenDisplayNamePatterns = [
/[\r\n\t]/,
/\s{3,}/,
/^\s|\s$/,
/#everyone|#here/i,
/@everyone|@here/i,
/\p{Cf}/u,
/\p{Cc}/u,
];
@ -25,7 +25,7 @@ const passwordRestrictions: genericValidation = {
};
const emailRestrictions: { regex: RegExp } = {
regex: /^[^\s#]+#[^\s#]+\.[^\s#]+$/,
regex: /^[^\s@]+@[^\s@]+\.[^\s@]+$/,
};
export {