Skip to content

Commit

Permalink
Minor fix
Browse files Browse the repository at this point in the history
Minor fix
  • Loading branch information
0x7c13 committed Mar 4, 2020
1 parent 8eaea55 commit e6a554e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Notepads/Controls/TextEditor/TextEditorCore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -782,7 +782,7 @@ public async void SearchInWeb()

// The maximum length of a URL in the address bar is 2048 characters
// Let's take 2000 here to make sure we are not exceeding the limit
// Otherwise we will see " Invalid URI: The uri string is too long" exception
// Otherwise we will see "Invalid URI: The uri string is too long" exception
var searchString = selectedText.Length <= 2000 ? selectedText : selectedText.Substring(0, 2000);

if (Uri.TryCreate(searchString, UriKind.Absolute, out var webUrl) && (webUrl.Scheme == Uri.UriSchemeHttp || webUrl.Scheme == Uri.UriSchemeHttps))
Expand Down

0 comments on commit e6a554e

Please sign in to comment.