forked from Supositware/Haha-Yes
This commit is contained in:
parent
d962698ad0
commit
aa77bd5d46
1 changed files with 5 additions and 2 deletions
|
@ -52,10 +52,13 @@ class facebookCommand extends Command {
|
||||||
}).then((response) => {
|
}).then((response) => {
|
||||||
return response.json();
|
return response.json();
|
||||||
}).then((response) => {
|
}).then((response) => {
|
||||||
let postID = response.id.slice(17);
|
console.log(response);
|
||||||
|
let postID;
|
||||||
|
if (response.id) {
|
||||||
|
postID = response.id.slice(17);
|
||||||
|
}
|
||||||
message.channel.send(`Go see ur epic post https://www.facebook.com/HahaYesDiscord/posts/${postID}`);
|
message.channel.send(`Go see ur epic post https://www.facebook.com/HahaYesDiscord/posts/${postID}`);
|
||||||
channel.send(`AUTHOR: ${message.author.username} (${message.author.id}) Sent: ${args.text}\nhttps://www.facebook.com/HahaYesDiscord/posts/${postID}`);
|
channel.send(`AUTHOR: ${message.author.username} (${message.author.id}) Sent: ${args.text}\nhttps://www.facebook.com/HahaYesDiscord/posts/${postID}`);
|
||||||
console.log(response);
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue