Skip to content

Commit b63d003

Browse files
authored
Allow alerts to be created if ALERT_SMTP_HOST is defined
The previous behavior only allowed email alerts in self-hosting if ALERT_RESEND_API_KEY was defined. This commit updates the environment check to also use ALERT_SMTP_HOST for alert email configuration. The ALERT_SMTP_HOST is already used in the SMPT client, so no other changes are necessary.
1 parent 3157b65 commit b63d003

File tree

1 file changed

+1
-1
lines changed
  • apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.alerts.new

1 file changed

+1
-1
lines changed

apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.alerts.new/route.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ export async function loader({ request, params }: LoaderFunctionArgs) {
158158
const option = url.searchParams.get("option");
159159

160160
const emailAlertsEnabled =
161-
env.ALERT_FROM_EMAIL !== undefined && env.ALERT_RESEND_API_KEY !== undefined;
161+
env.ALERT_FROM_EMAIL !== undefined && (env.ALERT_RESEND_API_KEY !== undefined || env.ALERT_SMTP_HOST !== undefined);
162162

163163
return typedjson({
164164
...results,

0 commit comments

Comments
 (0)