feat: migrate away from trello (#2)

Closes #1

Reviewed-on: https://codeberg.org/nhcarrigan/a4p-bot/pulls/2
Co-authored-by: Naomi <commits@nhcarrigan.com>
Co-committed-by: Naomi <commits@nhcarrigan.com>
This commit is contained in:
2024-05-21 05:11:11 +00:00
committed by Naomi Carrigan
parent bbd6a710bb
commit a85b478dba
16 changed files with 2182 additions and 1856 deletions
+2 -8
View File
@@ -11,6 +11,8 @@ import { ExtendedClient } from "../interface/ExtendedClient";
/**
* Instantiates the web server for listening to webhook payloads.
*
* TODO: Delete this entirely once all trello things are done.
*
* @param {ExtendedClient} bot The bot's Discord instance.
*/
export const serve = async (bot: ExtendedClient) => {
@@ -80,14 +82,6 @@ export const serve = async (bot: ExtendedClient) => {
await bot.dist.send({
content: `${card.name} | [Trello Card](<${card.url}>) | ${contact}\nYou can ignore this ID it's just for the bot: ${card.id}`,
});
await bot.db.rewards.update({
where: {
trelloId: card.id,
},
data: {
completed: true,
},
});
});
const httpServer = http.createServer(app);