Skip to content

Conversation

@zbalkan
Copy link

@zbalkan zbalkan commented Jan 29, 2026

As the title says "TryParse must fail on empty string, whitespace and null strings", but it throws exception on string.Split() method. This case can be handled easily with a guard clause.

Copilot AI review requested due to automatic review settings January 29, 2026 17:34
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a bug in DomainEndPoint.TryParse where the method would throw an exception when called with null, empty, or whitespace strings instead of gracefully returning false.

Changes:

  • Added a guard clause to validate the input string before attempting to parse it

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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.

1 participant