mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-12-13 22:00:28 +05:30
parent
f35dd1c346
commit
d6803372f2
@ -183,7 +183,7 @@ const mixin = {
|
||||
const emailRegex = /([\w-\\.]+@(?:[\w-]+\.)+[\w-]{2,4})/g;
|
||||
return string
|
||||
.replace(urlRegex, url => {
|
||||
if (url.endsWith("</a>")) return url;
|
||||
if (url.endsWith("</a>") || url.endsWith("<a")) return url;
|
||||
return `<a href="${url}" target="_blank">${url}</a>`;
|
||||
})
|
||||
.replace(emailRegex, email => {
|
||||
|
Loading…
Reference in New Issue
Block a user