From 88d48715c5d31ab0c645f76a738d680247ccc60d Mon Sep 17 00:00:00 2001 From: Bradley Schofield Date: Mon, 28 Aug 2023 06:53:26 +0100 Subject: [PATCH] Run Linter --- app/controllers/api/projects.php | 2 +- app/controllers/api/teams.php | 2 +- app/workers/mails.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controllers/api/projects.php b/app/controllers/api/projects.php index e6f568e995..845a1f0e9a 100644 --- a/app/controllers/api/projects.php +++ b/app/controllers/api/projects.php @@ -1734,7 +1734,7 @@ App::patch('/v1/projects/:projectId/templates/email/:type/:locale') } $smtpEnabled = $project->getAttribute('smtp', [])['enabled'] ?? false; - if(!$smtpEnabled) { + if (!$smtpEnabled) { throw new Exception(Exception::PROJECT_SMTP_CONFIG_NOT_FOUND); } diff --git a/app/controllers/api/teams.php b/app/controllers/api/teams.php index aae105f0b8..3941e810d8 100644 --- a/app/controllers/api/teams.php +++ b/app/controllers/api/teams.php @@ -553,7 +553,7 @@ App::post('/v1/teams/:teamId/memberships') $body = Template::fromString($customTemplate['message'] ?? ''); $subject = $customTemplate['subject'] ?? $subject; $from = $customTemplate['senderName'] ?? $from; - + $smtp = $project->getAttribute('smtp', []); $mails ->setSmtpHost($smtp['host'] ?? '') diff --git a/app/workers/mails.php b/app/workers/mails.php index 2d7620d76f..c6f79187f3 100644 --- a/app/workers/mails.php +++ b/app/workers/mails.php @@ -43,7 +43,7 @@ class MailsV1 extends Worker $body = Template::fromFile(__DIR__ . '/../config/locale/templates/email-base.tpl'); foreach ($variables as $key => $value) { - $body->setParam('{{'.$key.'}}', $value); + $body->setParam('{{' . $key . '}}', $value); } $body = $body->render();