Fix sending links if they didn't get changed
Some checks failed
CI / CI (push) Has been cancelled

This commit is contained in:
SileNce5k 2026-02-27 19:55:37 +01:00
commit bc497c7dea
Signed by: SileNce
GPG key ID: B0A142BB4291B204
2 changed files with 2 additions and 8 deletions

View file

@ -12,11 +12,8 @@ module.exports = {
const regex = /(?<=\/)(instagram)\.com/g
if(args[0].startsWith("https://") || args[0].startsWith("http://")){
replacedLink = args[0].replace(regex, "kkinstagram.com");
}else {
message.channel.send(noUrlErr);
return;
}
if(replacedLink.length === 0){
if(replacedLink.length === 0 || args[0] === replacedLink){
message.channel.send(noUrlErr);
return;
}

View file

@ -12,11 +12,8 @@ module.exports = {
const regex = /(?<=\/)(x|twitter)\.com/g
if(args[0].startsWith("https://") || args[0].startsWith("http://")){
replacedLink = args[0].replace(regex, "fxtwitter.com");
}else {
message.channel.send(noUrlErr);
return;
}
if(replacedLink.length === 0){
if(replacedLink.length === 0 || args[0] === replacedLink){
message.channel.send(noUrlErr);
return;
}