Transférer les fichiers vers ''

This commit is contained in:
Aoi 2021-08-26 17:56:22 +00:00
parent 5d8ebd2142
commit c9d453db0d

View file

@ -22,6 +22,14 @@ app.post( '/', async ( req, res ) => {
res.sendStatus( 200 ); res.sendStatus( 200 );
} ); } );
app.post( '/github/', async ( req, res ) => {
console.log( 'received webhook', req.body );
if (req.body.issue.url =! undefined) {
(await client.channels.fetch("01FE139SQHRFBG5TR8022BECRW")).sendMessage(`**${req.body.sender.login} :**\n> __[${req.body.repository.full_name} - Issue ${req.body.issue.title} was Updated](${req.body.issue.url})`)
}
res.sendStatus( 200 );
} );
// client.on('packet', async () => { // client.on('packet', async () => {
// (await client.channels.fetch("01FE139SQHRFBG5TR8022BECRW")).sendMessage(`Why am I even logging this? Idk\n\`\`\`js\n{\n"date": "${Date.now()}",\n"a": "${client.users.name_}"\n}`) // (await client.channels.fetch("01FE139SQHRFBG5TR8022BECRW")).sendMessage(`Why am I even logging this? Idk\n\`\`\`js\n{\n"date": "${Date.now()}",\n"a": "${client.users.name_}"\n}`)
//}); //});