Simplify
This commit is contained in:
parent
34ece16aaa
commit
dd2a5bb6e9
@ -4422,7 +4422,7 @@
|
||||
if (g.VIEW === 'catalog' || !Conf['Linkify']) {
|
||||
return;
|
||||
}
|
||||
this.regString = /((https?|mailto|git|magnet|ftp|irc):([a-z\d%\/])|www\d{0,3}[.]|[-a-z\d.]+[.](aero|asia|biz|cat|com|coop|info|int|jobs|mobi|museum|name|net|org|post|pro|tel|travel|xxx|edu|gov|mil|[a-z]{2})(\/|\z)|[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}|[-\w\d.@]+@[a-z\d.-]+\.[a-z\d])/i;
|
||||
this.regString = /((https?|mailto|git|magnet|ftp|irc):([a-z\d%\/])|[-a-z\d.]+[.](aero|asia|biz|cat|com|coop|info|int|jobs|mobi|museum|name|net|org|post|pro|tel|travel|xxx|edu|gov|mil|[\d]{1,3}|[a-z]{2})(\/|\z)|[-\w\d.@]+@[a-z\d.-]+\.[a-z\d])/i;
|
||||
if (Conf['Comment Expansion']) {
|
||||
ExpandComment.callbacks.push(this.node);
|
||||
}
|
||||
|
||||
@ -4431,7 +4431,7 @@
|
||||
if (g.VIEW === 'catalog' || !Conf['Linkify']) {
|
||||
return;
|
||||
}
|
||||
this.regString = /((https?|mailto|git|magnet|ftp|irc):([a-z\d%\/])|www\d{0,3}[.]|[-a-z\d.]+[.](aero|asia|biz|cat|com|coop|info|int|jobs|mobi|museum|name|net|org|post|pro|tel|travel|xxx|edu|gov|mil|[a-z]{2})(\/|\z)|[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}|[-\w\d.@]+@[a-z\d.-]+\.[a-z\d])/i;
|
||||
this.regString = /((https?|mailto|git|magnet|ftp|irc):([a-z\d%\/])|[-a-z\d.]+[.](aero|asia|biz|cat|com|coop|info|int|jobs|mobi|museum|name|net|org|post|pro|tel|travel|xxx|edu|gov|mil|[\d]{1,3}|[a-z]{2})(\/|\z)|[-\w\d.@]+@[a-z\d.-]+\.[a-z\d])/i;
|
||||
if (Conf['Comment Expansion']) {
|
||||
ExpandComment.callbacks.push(this.node);
|
||||
}
|
||||
|
||||
@ -9,16 +9,11 @@ Linkify =
|
||||
[a-z\d%/]
|
||||
)
|
||||
|
|
||||
www\d{0,3}[.]
|
||||
|
|
||||
# This should account for virtually all links posted without www or http:
|
||||
# This should account for virtually all links posted without www or http:, including IPv4 addresses
|
||||
[-a-z\d.]+[.](
|
||||
aero|asia|biz|cat|com|coop|info|int|jobs|mobi|museum|name|net|org|post|pro|tel|travel|xxx|edu|gov|mil|[a-z]{2}
|
||||
aero|asia|biz|cat|com|coop|info|int|jobs|mobi|museum|name|net|org|post|pro|tel|travel|xxx|edu|gov|mil|[\d]{1,3}|[a-z]{2}
|
||||
)(/|\z)
|
||||
|
|
||||
# IPv4 Addresses
|
||||
[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}
|
||||
|
|
||||
# E-mails
|
||||
[-\w\d.@]+@[a-z\d.-]+\.[a-z\d]
|
||||
)///i
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user