mirror of
https://codeberg.org/ashley/poke.git
synced 2024-12-25 08:18:43 +01:00
add referer remover :3
This commit is contained in:
parent
eef471c9a2
commit
da3bffcbf5
1 changed files with 1 additions and 1 deletions
|
@ -201,7 +201,7 @@ module.exports = function (app, config, renderTemplate) {
|
|||
|
||||
return text.replace(urlRegex, (url) => {
|
||||
// wrap the URL in an <a> tag with the URL as the href attribute
|
||||
return `<a href="${url.replace("https://youtube.com", "").replace("https://youtu.be", "")}" target="_blank">${url}</a>`;
|
||||
return `<a href="/api/redirect?u=${btoa(url.replace(/twitter\.com/g, "nitter.net").replace(/reddit\.com/g, "teddit.net").replace("https://youtube.com", "").replace("https://youtu.be", ""))}" target="_blank">${url}</a>`;
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue