From 686fff945e0b4697aa74da404ce90534bb7b121d Mon Sep 17 00:00:00 2001 From: Jonas Kohl Date: Thu, 26 Dec 2024 20:12:34 +0100 Subject: Add async email and topic subscribing --- src/application/mystic/forum/Database.php | 4 ++-- src/application/mystic/forum/orm/PendingEmail.php | 19 +++++++++++++++++++ src/application/mystic/forum/orm/Subscription.php | 14 ++++++++++++++ src/application/mystic/forum/utils/StringUtils.php | 2 ++ 4 files changed, 37 insertions(+), 2 deletions(-) create mode 100644 src/application/mystic/forum/orm/PendingEmail.php create mode 100644 src/application/mystic/forum/orm/Subscription.php (limited to 'src/application/mystic/forum') diff --git a/src/application/mystic/forum/Database.php b/src/application/mystic/forum/Database.php index 1c2d710..bca4ac9 100644 --- a/src/application/mystic/forum/Database.php +++ b/src/application/mystic/forum/Database.php @@ -46,12 +46,12 @@ class Database { protected function queryParams(string $query, array $params): Result|false { ++$this->queryCount; - return \pg_query_params ($this->connection, $query, $params); + return \pg_query_params($this->connection, $query, $params); } protected function query(string $query): Result|false { ++$this->queryCount; - return \pg_query ($this->connection, $query); + return \pg_query($this->connection, $query); } public static function generateId(int $length = 64): string { diff --git a/src/application/mystic/forum/orm/PendingEmail.php b/src/application/mystic/forum/orm/PendingEmail.php new file mode 100644 index 0000000..70622b3 --- /dev/null +++ b/src/application/mystic/forum/orm/PendingEmail.php @@ -0,0 +1,19 @@ +