1 if(command === "gif"){
2 const gifSearch =require('gif-search');
3 const gif = args.join(" ")
4 try{
5 gifSearch.query(gif).then((gifurl) =>{
6 const embed = new discord.MessageEmbed()
7 .setTitle("Result for "+saymessage)
8 .setImage(gifurl)
9 .setFooter("Requested by "+message.author.username)
10 message.channel.send(embed)
11 }).catch(error)}
12 catch(error){message.channel.send("NO gif found")}
13 }
14 //I hope it helps ;)