From 5192cbc944c48d1195e014932cb12c3286e77439 Mon Sep 17 00:00:00 2001 From: ZwF <25246962+devzwf@users.noreply.github.com> Date: Thu, 23 Nov 2023 14:12:58 -0500 Subject: [PATCH 1/2] fix email from field in the DB the field is from_email and not fromEmail --- endpoints/cronjobs/sendnotifications.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/endpoints/cronjobs/sendnotifications.php b/endpoints/cronjobs/sendnotifications.php index 1632f83..719a3d4 100644 --- a/endpoints/cronjobs/sendnotifications.php +++ b/endpoints/cronjobs/sendnotifications.php @@ -16,7 +16,7 @@ $smtpPort = $row["smtp_port"]; $smtpUsername = $row["smtp_username"]; $smtpPassword = $row["smtp_password"]; - $fromEmail = $row["fromEmail"] ?? "wallos@wallosapp.com"; + $fromEmail = $row["from_email"] ?? "wallos@wallosapp.com"; } else { echo "Notifications are disabled. No need to run."; } @@ -87,4 +87,4 @@ } } -?> \ No newline at end of file +?> From 3d8329856787bb5b2bde67976e1c4915b2635483 Mon Sep 17 00:00:00 2001 From: ZwF <25246962+devzwf@users.noreply.github.com> Date: Thu, 23 Nov 2023 14:14:42 -0500 Subject: [PATCH 2/2] name of array case sensitive fix the use of fromemail for testing the email. --- endpoints/notifications/sendtestmail.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/endpoints/notifications/sendtestmail.php b/endpoints/notifications/sendtestmail.php index 1462544..80072cf 100644 --- a/endpoints/notifications/sendtestmail.php +++ b/endpoints/notifications/sendtestmail.php @@ -31,7 +31,7 @@ if ($_SERVER["REQUEST_METHOD"] === "POST") { $smtpPort = $data["smtpport"]; $smtpUsername = $data["smtpusername"]; $smtpPassword = $data["smtppassword"]; - $fromEmail = $data["fromEmail"] ?? "wallos@wallosapp.com"; + $fromEmail = $data["fromemail"] ?? "wallos@wallosapp.com"; $mail = new PHPMailer(true); $mail->isSMTP();