Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't send auth when both user and pass are empty #566

Merged
merged 1 commit into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .devcontainer/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ services:
volumes:
- .:/workspaces:cached
environment:
NEXTAUTH_URL: "http://10.0.0.217:3000" # Update this to the URL of your dev environment
NEXTAUTH_URL: "${NEXTAUTH_URL:-http://10.0.0.217:3000}"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change was to ensure dev container development works properly.

networks:
- app-network
depends_on:
Expand Down
11 changes: 7 additions & 4 deletions src/utils/mail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,10 +277,13 @@ export async function createTransporter() {
host: globalOptions.smtpHost,
port: globalOptions.smtpPort,
secure: globalOptions.smtpUseSSL,
auth: {
user: globalOptions.smtpUsername,
pass: globalOptions.smtpPassword,
},
auth:
globalOptions.smtpUsername || globalOptions.smtpPassword
? {
user: globalOptions.smtpUsername,
pass: globalOptions.smtpPassword,
}
: undefined,
tls: {
rejectUnauthorized: true,
minVersion: "TLSv1.2",
Expand Down
Loading