Remove new lines from domain name part of autolinker regular expression in Util\Strings
- Fixes issue where the autolinker would include the next paragraph is a pathless URL was followed by new lines.
This commit is contained in:
@@ -361,7 +361,7 @@ class Strings
|
|||||||
( # Capture 1: entire matched URL
|
( # Capture 1: entire matched URL
|
||||||
https?:// # http or https protocol
|
https?:// # http or https protocol
|
||||||
(?:
|
(?:
|
||||||
[^/.][^/]+[.][^/]+/? # looks like domain name followed by a slash
|
[^/\s.][^/\s]+[.][^\s/]+/? # looks like domain name followed by a slash
|
||||||
)
|
)
|
||||||
(?: # One or more:
|
(?: # One or more:
|
||||||
[^\s()<>]+ # Run of non-space, non-()<>
|
[^\s()<>]+ # Run of non-space, non-()<>
|
||||||
|
|||||||
Reference in New Issue
Block a user