Skip to content

Conversation

@Dmitry-VF
Copy link
Contributor

Description of Change

Issues Resolved

  • fixes #

API Changes

None

Platforms Affected

  • All
  • WPF
  • UWP
  • iOS
  • Android

Behavioral Changes

None

Testing Procedure

PR Checklist

  • I have included examples or tests
  • I have updated the change log
  • I am listed in the CONTRIBUTORS file
  • Rebased on top of the target branch at time of PR
  • Changes adhere to coding standard

return;
}

if (!uri.IsAbsoluteUri || !(uri.Scheme.StartsWith("http", StringComparison.OrdinalIgnoreCase)
Copy link
Contributor

Choose a reason for hiding this comment

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

uri.Scheme.StartsWith("http", StringComparison.OrdinalIgnoreCase) || uri.Scheme.StartsWith("https", StringComparison.OrdinalIgnoreCase) === uri.Scheme.StartsWith("http", StringComparison.OrdinalIgnoreCase)

Copy link
Member

Choose a reason for hiding this comment

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

I think Catel even has StartsWithIgnoreCase and StartsWithAnyIgnoreCase

|| uri.Scheme.StartsWith("https", StringComparison.OrdinalIgnoreCase)))
{
string modifiedUriString;
if (uri.IsAbsoluteUri)
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe there is a way not to check it twice

Copy link
Member

@GeertvanHorrik GeertvanHorrik left a comment

Choose a reason for hiding this comment

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

Unit tests are missing.

But, for example, what if I want to launch an app like this:

myapp://myaction

Will that no longer be possible?

return;
}

if (!uri.IsAbsoluteUri || !(uri.Scheme.StartsWith("http", StringComparison.OrdinalIgnoreCase)
Copy link
Member

Choose a reason for hiding this comment

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

I think Catel even has StartsWithIgnoreCase and StartsWithAnyIgnoreCase

Copy link
Member

@GeertvanHorrik GeertvanHorrik left a comment

Choose a reason for hiding this comment

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

How can we be sure the behavior is correct if unit tests are missing?

Copy link
Member

@GeertvanHorrik GeertvanHorrik left a comment

Choose a reason for hiding this comment

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

Looks great!

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.

4 participants