Only recognize common url schemes in notification messages
Before the fix, the message tray highlighted all urls containing "://", even invalid ones. This change fixes this by have the message tray highlight only the urls with http, https, ftp schemes. Credit goes to: Phuong Vu, Liye Fu, Monica Chelliah, Owen Taylor https://bugzilla.gnome.org/show_bug.cgi?id=661225
This commit is contained in:
parent
9ae2440ec1
commit
608818fa9f
@ -18,7 +18,7 @@ const _urlRegexp = new RegExp(
|
|||||||
'(^|' + _leadingJunk + ')' +
|
'(^|' + _leadingJunk + ')' +
|
||||||
'(' +
|
'(' +
|
||||||
'(?:' +
|
'(?:' +
|
||||||
'[a-z][\\w-]+://' + // scheme://
|
'(?:http|https|ftp)://' + // scheme://
|
||||||
'|' +
|
'|' +
|
||||||
'www\\d{0,3}[.]' + // www.
|
'www\\d{0,3}[.]' + // www.
|
||||||
'|' +
|
'|' +
|
||||||
|
Loading…
Reference in New Issue
Block a user