Skip to content

Commit

Permalink
only increase if matched with http(s)
Browse files Browse the repository at this point in the history
  • Loading branch information
Outfluencer authored Aug 5, 2024
1 parent d65a252 commit b527c44
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
public final class TextComponent extends BaseComponent
{

private static final Pattern url = Pattern.compile( "^(?:(https?)://)?([-\\w_\\.]{2,}\\.[a-z-]{2,24})(/\\S*)?$" );
private static final Pattern url = Pattern.compile( "^(?:https?://([-\\w_\\.]+\\.[a-z-]{2,24})|([-\\w_\\.]{2,}\\.[a-z]{2,4}))(/\\S*)?$" );

/**
* Converts the old formatting system that used
Expand Down

0 comments on commit b527c44

Please sign in to comment.