Skip to content

Don't blow up when sending email without portal#7058

Merged
bdukes merged 1 commit intodnnsoftware:release/10.2.3from
bdukes:mailsettings-portal
Mar 3, 2026
Merged

Don't blow up when sending email without portal#7058
bdukes merged 1 commit intodnnsoftware:release/10.2.3from
bdukes:mailsettings-portal

Conversation

@bdukes
Copy link
Copy Markdown
Contributor

@bdukes bdukes commented Mar 3, 2026

Fixes #7052

This PR causes the mail providers to fall back to a portal ID of -1 if PortalSettings.Current is null. This prevents a NullReferenceException.

Ideally, there would be a way to specify a portal when sending an email from a scheduled task. We could add a property to MailInfo to support that scenario.

@bdukes bdukes added this to the 10.2.4 milestone Mar 3, 2026
@valadas
Copy link
Copy Markdown
Contributor

valadas commented Mar 3, 2026

@bdukes since this is a regression in 10.2.3, should we fix that branch?

@bdukes bdukes changed the base branch from develop to release/10.2.3 March 3, 2026 19:42
@bdukes bdukes modified the milestones: 10.2.4, 10.2.3 Mar 3, 2026
@bdukes
Copy link
Copy Markdown
Contributor Author

bdukes commented Mar 3, 2026

Yup, I hadn't looked closely at where I'd introduced the issue. I've changed the base branch for the PR

Copy link
Copy Markdown
Contributor

@valadas valadas left a comment

Choose a reason for hiding this comment

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

Thanks

@valadas
Copy link
Copy Markdown
Contributor

valadas commented Mar 3, 2026

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@bdukes bdukes enabled auto-merge (rebase) March 3, 2026 21:08
@bdukes bdukes merged commit 10c4cb5 into dnnsoftware:release/10.2.3 Mar 3, 2026
3 checks passed
@bdukes bdukes deleted the mailsettings-portal branch March 3, 2026 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Mailkit Provider fails to send mails from a scheduled JOB

4 participants