@ -137,7 +137,11 @@ class ytpCommand extends Command {
if(err){
if(err){
console.error(err);
console.error(err);
loadingmsg.delete();
loadingmsg.delete();
returnmessage.channel.send('An error has occured, I can\'t download from the link you provided. Is it an mp4?');
if(err.includes('HTTP Error 429')){
returnmessage.channel.send('An error has occured, I can\'t download from the link you provided because the website has blocked the bot. Please try again later or upload that video as mp4 on another website.');
}else{
returnmessage.channel.send('An error has occured, I can\'t download from the link you provided. Is it an mp4?');
}
}else{
}else{
if(output[2]){
if(output[2]){
if(output[2].includes('File is larger than max-filesize')){
if(output[2].includes('File is larger than max-filesize')){
@ -76,8 +76,11 @@ class DownloadCommand extends Command {
if(err){
if(err){
console.error(err);
console.error(err);
loadingmsg.delete();
loadingmsg.delete();
returnmessage.channel.send('An error has occured, I can\'t download from the link you provided.');
if(err.includes('HTTP Error 429')){
}
returnmessage.channel.send('An error has occured, I can\'t download from the link you provided because the website has blocked the bot. Please try again later.');
}else{
returnmessage.channel.send('An error has occured, I can\'t download from the link you provided.');