Skip to content

Don't try to add empty attendee caladdress#273

Merged
sunkup merged 1 commit intoical4j-3to4from
211-jtx-board-npe-when-adding-non-email-address-attendee
Apr 1, 2026
Merged

Don't try to add empty attendee caladdress#273
sunkup merged 1 commit intoical4j-3to4from
211-jtx-board-npe-when-adding-non-email-address-attendee

Conversation

@sunkup
Copy link
Copy Markdown
Member

@sunkup sunkup commented Mar 31, 2026

Closes #211

The caladdress for attendees usually contains the email with "mailto" format. It is however optional for attendees and could be empty or null. We were parsing the nullable email caladdress value for attendees using java.net.URI, which then threw. Adding a null-check solves the issue and not adding the caladress when it is not present is ok, since it's optional. We don't always have to infer it.

I have not added a test for the modified method addProperties here, since the JtxICalObject is due for refactoring to the new builder/handler pattern with better tests soon anyways.

@sunkup sunkup self-assigned this Mar 31, 2026
@sunkup sunkup added the pr-bugfix Fixes something that isn't working (only used for PRs) label Mar 31, 2026
@sunkup sunkup linked an issue Mar 31, 2026 that may be closed by this pull request
@sunkup sunkup requested a review from ArnyminerZ March 31, 2026 09:49
@sunkup sunkup marked this pull request as ready for review March 31, 2026 09:49
@sunkup sunkup changed the title Don't try add empty attendee caladdress Don't try to add empty attendee caladdress Apr 1, 2026
Copy link
Copy Markdown
Member

@ArnyminerZ ArnyminerZ left a comment

Choose a reason for hiding this comment

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

Good to go 👍🏼

@sunkup sunkup merged commit 5d0c2b7 into ical4j-3to4 Apr 1, 2026
4 checks passed
@sunkup sunkup deleted the 211-jtx-board-npe-when-adding-non-email-address-attendee branch April 1, 2026 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-bugfix Fixes something that isn't working (only used for PRs)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[jtx Board] NPE when adding non-email-address attendee

2 participants