Skip to content

Conversation

rdestefa
Copy link
Contributor

@rdestefa rdestefa commented Oct 4, 2025

Implements #298. Would be nice to have this additional functionality, so took a stab at a PR for this.

Can add a changelog entry if the current approach looks good.

Copy link
Collaborator

@robinst robinst left a comment

Choose a reason for hiding this comment

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

Very nice, thanks for working on this!

I've left some comments in the PR for you to address, but overall great work.


if (linkTypes.length == 0) {
throw new IllegalArgumentException("linkTypes must not be empty");
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

No need to duplicate the checks above if we're delegating to linkTypes(Set<AutolinkType> linkTypes) anyway.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed the second check. The first check was just to provide a more explicit error message than whatever is thrown by calling Set.of(null), but I can remove if we think that's unnecessary.

@rdestefa rdestefa requested a review from robinst October 6, 2025 08:59
@rdestefa
Copy link
Contributor Author

rdestefa commented Oct 7, 2025

Thanks for the reviews! I think all comments should be addressed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants