From ee1d8ab4a51f10b35db4a9b485ab0e6793dd554a Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Sun, 26 May 2024 23:02:11 +0000 Subject: [PATCH 01/16] Update dependency discord.js to v14.15.2 --- package-lock.json | 122 ++++++++++++++++++++++++---------------------- 1 file changed, 64 insertions(+), 58 deletions(-) diff --git a/package-lock.json b/package-lock.json index 368aee4..7c81d71 100644 --- a/package-lock.json +++ b/package-lock.json @@ -732,19 +732,24 @@ } }, "node_modules/@discordjs/builders": { - "version": "1.7.0", + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-1.8.1.tgz", + "integrity": "sha512-GkF+HM01FHy+NSoTaUPR8z44otfQgJ1AIsRxclYGUZDyUbdZEFyD/5QVv2Y1Flx6M+B0bQLzg2M9CJv5lGTqpA==", "license": "Apache-2.0", "dependencies": { - "@discordjs/formatters": "^0.3.3", - "@discordjs/util": "^1.0.2", - "@sapphire/shapeshift": "^3.9.3", - "discord-api-types": "0.37.61", + "@discordjs/formatters": "^0.4.0", + "@discordjs/util": "^1.1.0", + "@sapphire/shapeshift": "^3.9.7", + "discord-api-types": "0.37.83", "fast-deep-equal": "^3.1.3", - "ts-mixer": "^6.0.3", + "ts-mixer": "^6.0.4", "tslib": "^2.6.2" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/@discordjs/collection": { @@ -760,13 +765,18 @@ } }, "node_modules/@discordjs/formatters": { - "version": "0.3.3", + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/@discordjs/formatters/-/formatters-0.4.0.tgz", + "integrity": "sha512-fJ06TLC1NiruF35470q3Nr1bi95BdvKFAF+T5bNfZJ4bNdqZ3VZ+Ttg6SThqTxm6qumSG3choxLBHMC69WXNXQ==", "license": "Apache-2.0", "dependencies": { - "discord-api-types": "0.37.61" + "discord-api-types": "0.37.83" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/@discordjs/rest": { @@ -792,22 +802,6 @@ "url": "https://github.com/discordjs/discord.js?sponsor" } }, - "node_modules/@discordjs/rest/node_modules/@sapphire/snowflake": { - "version": "3.5.3", - "resolved": "https://registry.npmjs.org/@sapphire/snowflake/-/snowflake-3.5.3.tgz", - "integrity": "sha512-jjmJywLAFoWeBi1W7994zZyiNWPIiqRRNAmSERxyg93xRGzNYvGjlZ0gR6x0F4gPRi2+0O6S71kOZYyr3cxaIQ==", - "license": "MIT", - "engines": { - "node": ">=v14.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/@discordjs/rest/node_modules/discord-api-types": { - "version": "0.37.83", - "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.37.83.tgz", - "integrity": "sha512-urGGYeWtWNYMKnYlZnOnDHm8fVRffQs3U0SpE8RHeiuLKb/u92APS8HoQnPTFbnXmY1vVnXjXO4dOxcAn3J+DA==", - "license": "MIT" - }, "node_modules/@discordjs/util": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@discordjs/util/-/util-1.1.0.tgz", @@ -821,21 +815,26 @@ } }, "node_modules/@discordjs/ws": { - "version": "1.0.2", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@discordjs/ws/-/ws-1.1.0.tgz", + "integrity": "sha512-O97DIeSvfNTn5wz5vaER6ciyUsr7nOqSEtsLoMhhIgeFkhnxLRqSr00/Fpq2/ppLgjDGLbQCDzIK7ilGoB/M7A==", "license": "Apache-2.0", "dependencies": { - "@discordjs/collection": "^2.0.0", - "@discordjs/rest": "^2.1.0", - "@discordjs/util": "^1.0.2", - "@sapphire/async-queue": "^1.5.0", - "@types/ws": "^8.5.9", - "@vladfrangu/async_event_emitter": "^2.2.2", - "discord-api-types": "0.37.61", + "@discordjs/collection": "^2.1.0", + "@discordjs/rest": "^2.3.0", + "@discordjs/util": "^1.1.0", + "@sapphire/async-queue": "^1.5.2", + "@types/ws": "^8.5.10", + "@vladfrangu/async_event_emitter": "^2.2.4", + "discord-api-types": "0.37.83", "tslib": "^2.6.2", - "ws": "^8.14.2" + "ws": "^8.16.0" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/@discordjs/ws/node_modules/@types/ws": { @@ -1715,19 +1714,22 @@ } }, "node_modules/@sapphire/shapeshift": { - "version": "3.9.3", + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/@sapphire/shapeshift/-/shapeshift-3.9.7.tgz", + "integrity": "sha512-4It2mxPSr4OGn4HSQWGmhFMsNFGfFVhWeRPCRwbH972Ek2pzfGRZtb0pJ4Ze6oIzcyh2jw7nUDa6qGlWofgd9g==", "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.3", "lodash": "^4.17.21" }, "engines": { - "node": ">=v14.0.0", - "npm": ">=7.0.0" + "node": ">=v16" } }, "node_modules/@sapphire/snowflake": { - "version": "3.5.1", + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/@sapphire/snowflake/-/snowflake-3.5.3.tgz", + "integrity": "sha512-jjmJywLAFoWeBi1W7994zZyiNWPIiqRRNAmSERxyg93xRGzNYvGjlZ0gR6x0F4gPRi2+0O6S71kOZYyr3cxaIQ==", "license": "MIT", "engines": { "node": ">=v14.0.0", @@ -2009,13 +2011,6 @@ "resolved": "https://registry.npmjs.org/@types/uuid/-/uuid-9.0.8.tgz", "integrity": "sha512-jg+97EGIcY9AGHJJRaaPVgetKDsrTgbRjQ5Msgjh/DQKEFl0DtyRr/VCOyD1T2R1MNeWPK/u7JoGhlDZnKBAfA==" }, - "node_modules/@types/ws": { - "version": "8.5.9", - "license": "MIT", - "dependencies": { - "@types/node": "*" - } - }, "node_modules/@types/yargs": { "version": "17.0.32", "license": "MIT", @@ -4241,34 +4236,41 @@ } }, "node_modules/discord-api-types": { - "version": "0.37.61", + "version": "0.37.83", + "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.37.83.tgz", + "integrity": "sha512-urGGYeWtWNYMKnYlZnOnDHm8fVRffQs3U0SpE8RHeiuLKb/u92APS8HoQnPTFbnXmY1vVnXjXO4dOxcAn3J+DA==", "license": "MIT" }, "node_modules/discord.js": { - "version": "14.14.1", + "version": "14.15.2", + "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-14.15.2.tgz", + "integrity": "sha512-wGD37YCaTUNprtpqMIRuNiswwsvSWXrHykBSm2SAosoTYut0VUDj9yo9t4iLtMKvuhI49zYkvKc2TNdzdvpJhg==", "license": "Apache-2.0", "dependencies": { - "@discordjs/builders": "^1.7.0", + "@discordjs/builders": "^1.8.1", "@discordjs/collection": "1.5.3", - "@discordjs/formatters": "^0.3.3", - "@discordjs/rest": "^2.1.0", - "@discordjs/util": "^1.0.2", - "@discordjs/ws": "^1.0.2", - "@sapphire/snowflake": "3.5.1", - "@types/ws": "8.5.9", - "discord-api-types": "0.37.61", + "@discordjs/formatters": "^0.4.0", + "@discordjs/rest": "^2.3.0", + "@discordjs/util": "^1.1.0", + "@discordjs/ws": "^1.1.0", + "@sapphire/snowflake": "3.5.3", + "discord-api-types": "0.37.83", "fast-deep-equal": "3.1.3", "lodash.snakecase": "4.1.1", "tslib": "2.6.2", - "undici": "5.27.2", - "ws": "8.14.2" + "undici": "6.13.0" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/discord.js/node_modules/@discordjs/collection": { "version": "1.5.3", + "resolved": "https://registry.npmjs.org/@discordjs/collection/-/collection-1.5.3.tgz", + "integrity": "sha512-SVb428OMd3WO1paV3rm6tSjM4wC+Kecaa1EUGX7vc6/fddvw/6lg90z4QtCqm21zvVe92vMMDt9+DkIvjXImQQ==", "license": "Apache-2.0", "engines": { "node": ">=16.11.0" @@ -10961,7 +10963,9 @@ } }, "node_modules/ts-mixer": { - "version": "6.0.3", + "version": "6.0.4", + "resolved": "https://registry.npmjs.org/ts-mixer/-/ts-mixer-6.0.4.tgz", + "integrity": "sha512-ufKpbmrugz5Aou4wcr5Wc1UUFWOLhq+Fm6qa6P0w0K5Qw2yhaUoiWszhCVuNQyNwrlGiscHOmqYoAox1PtvgjA==", "license": "MIT" }, "node_modules/tslib": { @@ -11652,7 +11656,9 @@ } }, "node_modules/ws": { - "version": "8.14.2", + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.0.tgz", + "integrity": "sha512-uJq6108EgZMAl20KagGkzCKfMEjxmKvZHG7Tlq0Z6nOky7YF7aq4mOx6xK8TJ/i1LeK4Qus7INktacctDgY8Ow==", "license": "MIT", "engines": { "node": ">=10.0.0" From 318b07e2066980c244e3fd7f4be1b6890d93213b Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Tue, 28 May 2024 17:58:30 +0100 Subject: [PATCH 02/16] Update dependency ts-jest to v29.1.3 (#241) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [ts-jest](https://kulshekhar.github.io/ts-jest) ([source](https://github.com/kulshekhar/ts-jest)) | dependencies | patch | [`29.1.2` -> `29.1.3`](https://renovatebot.com/diffs/npm/ts-jest/29.1.2/29.1.3) | --- ### Release Notes
kulshekhar/ts-jest (ts-jest) ### [`v29.1.3`](https://github.com/kulshekhar/ts-jest/blob/HEAD/CHANGELOG.md#2913-2024-05-21) [Compare Source](https://github.com/kulshekhar/ts-jest/compare/v29.1.2...v29.1.3) ##### Bug Fixes - add `@jest/transform` as an optional peer dependency ([0ba7f86](https://github.com/kulshekhar/ts-jest/commit/0ba7f861c3e1905de5627b4e5d2a2cadad011b67)) - bring back Node 14 support ([eda56a7](https://github.com/kulshekhar/ts-jest/commit/eda56a779789d70963b7572e2914b2a3a25ac43a)) ##### Performance Improvements - remove ts resolved module cache file ([4c88da5](https://github.com/kulshekhar/ts-jest/commit/4c88da58991b000aa90ea489acfa6aed39b36120))
--- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). Reviewed-on: https://git.vylpes.xyz/External/card-drop/pulls/241 Co-authored-by: Renovate Bot Co-committed-by: Renovate Bot --- package-lock.json | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 368aee4..4d5be22 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10919,9 +10919,10 @@ } }, "node_modules/ts-jest": { - "version": "29.1.2", - "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.2.tgz", - "integrity": "sha512-br6GJoH/WUX4pu7FbZXuWGKGNDuU7b8Uj77g/Sp7puZV6EXzuByl6JrECvm0MzVzSTkSHWTihsXt+5XYER5b+g==", + "version": "29.1.3", + "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.1.3.tgz", + "integrity": "sha512-6L9qz3ginTd1NKhOxmkP0qU3FyKjj5CPoY+anszfVn6Pmv/RIKzhiMCsH7Yb7UvJR9I2A64rm4zQl531s2F1iw==", + "license": "MIT", "dependencies": { "bs-logger": "0.x", "fast-json-stable-stringify": "2.x", @@ -10936,10 +10937,11 @@ "ts-jest": "cli.js" }, "engines": { - "node": "^16.10.0 || ^18.0.0 || >=20.0.0" + "node": "^14.15.0 || ^16.10.0 || ^18.0.0 || >=20.0.0" }, "peerDependencies": { "@babel/core": ">=7.0.0-beta.0 <8", + "@jest/transform": "^29.0.0", "@jest/types": "^29.0.0", "babel-jest": "^29.0.0", "jest": "^29.0.0", @@ -10949,6 +10951,9 @@ "@babel/core": { "optional": true }, + "@jest/transform": { + "optional": true + }, "@jest/types": { "optional": true }, From 297e34e1cf45d8c8c0a735e50904f89f8a7d87a6 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Wed, 29 May 2024 17:36:58 +0100 Subject: [PATCH 03/16] Fix bug where large file attachments would cause claiming to fail interaction --- .gitignore | 1 + src/buttonEvents/Claim.ts | 12 ++++-------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index aecb458..a9ed469 100644 --- a/.gitignore +++ b/.gitignore @@ -108,4 +108,5 @@ config.json ormconfig.json gdrive-credentials.json data/ +.temp/ *.db \ No newline at end of file diff --git a/src/buttonEvents/Claim.ts b/src/buttonEvents/Claim.ts index 6c45900..3450dc4 100644 --- a/src/buttonEvents/Claim.ts +++ b/src/buttonEvents/Claim.ts @@ -1,17 +1,17 @@ -import { AttachmentBuilder, ButtonInteraction } from "discord.js"; +import { ButtonInteraction } from "discord.js"; import { ButtonEvent } from "../type/buttonEvent"; import Inventory from "../database/entities/app/Inventory"; import { CoreClient } from "../client/client"; import { default as eClaim } from "../database/entities/app/Claim"; import AppLogger from "../client/appLogger"; import CardDropHelperMetadata from "../helpers/CardDropHelperMetadata"; -import { readFileSync } from "fs"; -import path from "path"; export default class Claim extends ButtonEvent { public override async execute(interaction: ButtonInteraction) { if (!interaction.guild || !interaction.guildId) return; + await interaction.deferUpdate(); + const cardNumber = interaction.customId.split(" ")[1]; const claimId = interaction.customId.split(" ")[2]; const droppedBy = interaction.customId.split(" ")[3]; @@ -52,17 +52,13 @@ export default class Claim extends ButtonEvent { return; } - const image = readFileSync(path.join(process.env.DATA_DIR!, "cards", card.card.path)); const imageFileName = card.card.path.split("/").pop()!; - const attachment = new AttachmentBuilder(image, { name: imageFileName }); - const embed = CardDropHelperMetadata.GenerateDropEmbed(card, inventory.Quantity, imageFileName, interaction.user.username); const row = CardDropHelperMetadata.GenerateDropButtons(card, claimId, interaction.user.id, true); - await interaction.update({ + await interaction.editReply({ embeds: [ embed ], - files: [ attachment ], components: [ row ], }); } From ba9ade0659644cec5098b5106d1a1282acc5c8c0 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Thu, 30 May 2024 17:28:43 +0100 Subject: [PATCH 04/16] 0.5.2 --- .env.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 3ff53e9..ef2c218 100644 --- a/.env.example +++ b/.env.example @@ -7,7 +7,7 @@ # any secret values. BOT_TOKEN= -BOT_VER=0.5.0 +BOT_VER=0.5.2 BOT_AUTHOR=Vylpes BOT_OWNERID=147392775707426816 BOT_CLIENTID=682942374040961060 From 34ea1f87d7bb199367f56f76b19144f19c1628ab Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Thu, 30 May 2024 17:34:22 +0100 Subject: [PATCH 05/16] 0.5.2 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index e93e59f..1b9c8e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "card-drop", - "version": "0.5.1", + "version": "0.5.2", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "card-drop", - "version": "0.5.1", + "version": "0.5.2", "license": "MIT", "dependencies": { "@discordjs/rest": "^2.0.0", diff --git a/package.json b/package.json index 178f288..b64eec3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "card-drop", - "version": "0.5.1", + "version": "0.5.2", "main": "./dist/bot.js", "typings": "./dist", "scripts": { From 696810e093d1412c9b654d0c643b5541e9ac8a6a Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sat, 1 Jun 2024 14:42:51 +0100 Subject: [PATCH 06/16] Update the give currency timer to give 10 coins every 20 minutes (#236) # Description Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. - Give the currency to a user every 20 minutes - This is enough so that they can run claim once every 20 minutes #204, #226, #229 ## Type of change Please delete options that are not relevant. - [x] Bug fix (non-breaking change which fixes an issue) # How Has This Been Tested? Please describe the tests that you ran to verify the changes. Provide instructions so we can reproduce. Please also list any relevant details to your test configuration. # Checklist - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [ ] My changes generate no new warnings - [ ] I have added tests that provde my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [ ] Any dependent changes have been merged and published in downstream modules Reviewed-on: https://git.vylpes.xyz/External/card-drop/pulls/236 Reviewed-by: VylpesTester Co-authored-by: Ethan Lane Co-committed-by: Ethan Lane --- src/client/client.ts | 2 +- src/constants/CardConstants.ts | 1 + src/timers/GiveCurrency.ts | 5 +++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/client/client.ts b/src/client/client.ts index 2dd9a29..384843d 100644 --- a/src/client/client.ts +++ b/src/client/client.ts @@ -79,7 +79,7 @@ export class CoreClient extends Client { .then(() => { AppLogger.LogInfo("Client", "App Data Source Initialised"); - const timerId = this._timerHelper.AddTimer("*/30 * * * * *", "Europe/London", GiveCurrency, false); + const timerId = this._timerHelper.AddTimer("*/20 * * * *", "Europe/London", GiveCurrency, false); this._timerHelper.StartTimer(timerId); }) .catch(err => { diff --git a/src/constants/CardConstants.ts b/src/constants/CardConstants.ts index dfc89b8..0a87e22 100644 --- a/src/constants/CardConstants.ts +++ b/src/constants/CardConstants.ts @@ -1,5 +1,6 @@ export default class CardConstants { public static readonly ClaimCost = 10; + public static readonly TimerGiveAmount = 10; public static readonly DailyCurrency = 100; public static readonly StartingCurrency = 300; } \ No newline at end of file diff --git a/src/timers/GiveCurrency.ts b/src/timers/GiveCurrency.ts index ad1a21a..c292025 100644 --- a/src/timers/GiveCurrency.ts +++ b/src/timers/GiveCurrency.ts @@ -1,4 +1,5 @@ import AppLogger from "../client/appLogger"; +import CardConstants from "../constants/CardConstants"; import User from "../database/entities/app/User"; export default async function GiveCurrency() { @@ -7,10 +8,10 @@ export default async function GiveCurrency() { const users = await User.FetchAll(User); for (const user of users) { - user.AddCurrency(5); + user.AddCurrency(CardConstants.TimerGiveAmount); } User.SaveAll(User, users); - AppLogger.LogInfo("Timers/GiveCurrency", `Successfully gave +5 currency to ${users.length} users`); + AppLogger.LogInfo("Timers/GiveCurrency", `Successfully gave +${CardConstants.TimerGiveAmount} currency to ${users.length} users`); } \ No newline at end of file From 916244b57cad5e4719d386c1579d246423a9e6ab Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sat, 1 Jun 2024 14:47:21 +0100 Subject: [PATCH 07/16] Add balance command (#244) # Description Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. - Create balance command #228 ## Type of change Please delete options that are not relevant. - [x] New feature (non-breaking change which adds functionality) # How Has This Been Tested? Please describe the tests that you ran to verify the changes. Provide instructions so we can reproduce. Please also list any relevant details to your test configuration. # Checklist - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [ ] My changes generate no new warnings - [ ] I have added tests that provde my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [ ] Any dependent changes have been merged and published in downstream modules Reviewed-on: https://git.vylpes.xyz/External/card-drop/pulls/244 Reviewed-by: VylpesTester Co-authored-by: Ethan Lane Co-committed-by: Ethan Lane --- src/commands/balance.ts | 28 ++++++++++++++++++++++++++++ src/registry.ts | 2 ++ 2 files changed, 30 insertions(+) create mode 100644 src/commands/balance.ts diff --git a/src/commands/balance.ts b/src/commands/balance.ts new file mode 100644 index 0000000..2dcba50 --- /dev/null +++ b/src/commands/balance.ts @@ -0,0 +1,28 @@ +import { CommandInteraction, EmbedBuilder, SlashCommandBuilder } from "discord.js"; +import { Command } from "../type/command"; +import User from "../database/entities/app/User"; +import EmbedColours from "../constants/EmbedColours"; + +export default class Balance extends Command { + constructor() { + super(); + + this.CommandBuilder = new SlashCommandBuilder() + .setName("balance") + .setDescription("Get your currency balance"); + } + + public override async execute(interaction: CommandInteraction) { + const user = await User.FetchOneById(User, interaction.user.id); + + let userBalance = user != null ? user.Currency : 0; + + const embed = new EmbedBuilder() + .setColor(EmbedColours.Ok) + .setTitle("Balance") + .setDescription(`You currently have **${userBalance} currency**!`) + .setFooter({ text: interaction.user.username, iconURL: interaction.user.avatarURL() ?? undefined }); + + await interaction.reply({ embeds: [ embed ]}); + } +} \ No newline at end of file diff --git a/src/registry.ts b/src/registry.ts index dc2770d..182418e 100644 --- a/src/registry.ts +++ b/src/registry.ts @@ -3,6 +3,7 @@ import { Environment } from "./constants/Environment"; // Global Command Imports import About from "./commands/about"; +import Balance from "./commands/balance"; import Daily from "./commands/daily"; import Drop from "./commands/drop"; import Gdrivesync from "./commands/gdrivesync"; @@ -30,6 +31,7 @@ export default class Registry { public static RegisterCommands() { // Global Commands CoreClient.RegisterCommand("about", new About()); + CoreClient.RegisterCommand("balance", new Balance()); CoreClient.RegisterCommand("daily", new Daily()); CoreClient.RegisterCommand("drop", new Drop()); CoreClient.RegisterCommand("gdrivesync", new Gdrivesync()); From 682f62d42b4615bda74748aab9c06843617bbfb5 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sat, 1 Jun 2024 14:49:13 +0100 Subject: [PATCH 08/16] Update the daily command text to be more user friendly (#246) # Description Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. - Update the daily command text to be more user friendly #202, #240 ## Type of change Please delete options that are not relevant. - [x] New feature (non-breaking change which adds functionality) # How Has This Been Tested? Please describe the tests that you ran to verify the changes. Provide instructions so we can reproduce. Please also list any relevant details to your test configuration. # Checklist - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [ ] My changes generate no new warnings - [ ] I have added tests that provde my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [ ] Any dependent changes have been merged and published in downstream modules Reviewed-on: https://git.vylpes.xyz/External/card-drop/pulls/246 Reviewed-by: VylpesTester Co-authored-by: Ethan Lane Co-committed-by: Ethan Lane --- src/commands/daily.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/commands/daily.ts b/src/commands/daily.ts index 172b942..65d69fc 100644 --- a/src/commands/daily.ts +++ b/src/commands/daily.ts @@ -38,6 +38,6 @@ export default class Daily extends Command { await user.Save(User, user); - await interaction.reply(`Given ${CardConstants.DailyCurrency} currency to ${interaction.user.username}`); + await interaction.reply(`Congratulations, you have claimed your daily ${CardConstants.DailyCurrency} currency! You now have ${user.Currency} currency and can claim again in 24 hours!`); } } \ No newline at end of file From 6b9d71758a6b936bb34869bd166df6f58453b98d Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sat, 1 Jun 2024 14:52:38 +0100 Subject: [PATCH 09/16] Add a warning to the logs if an ID is used twice (#248) # Description Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. - Make the bot log a warning if the card metadata function finds duplicated ids #233 ## Type of change Please delete options that are not relevant. - [x] New feature (non-breaking change which adds functionality) # How Has This Been Tested? Please describe the tests that you ran to verify the changes. Provide instructions so we can reproduce. Please also list any relevant details to your test configuration. # Checklist - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [ ] I have made corresponding changes to the documentation - [ ] My changes generate no new warnings - [ ] I have added tests that provde my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [ ] Any dependent changes have been merged and published in downstream modules Reviewed-on: https://git.vylpes.xyz/External/card-drop/pulls/248 Reviewed-by: VylpesTester Co-authored-by: Ethan Lane Co-committed-by: Ethan Lane --- src/Functions/CardMetadataFunction.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Functions/CardMetadataFunction.ts b/src/Functions/CardMetadataFunction.ts index 733c50c..a2499d9 100644 --- a/src/Functions/CardMetadataFunction.ts +++ b/src/Functions/CardMetadataFunction.ts @@ -39,6 +39,13 @@ export default class CardMetadataFunction { CoreClient.Cards = cardResult.Result!; AppLogger.LogInfo("Functions/CardMetadataFunction", `Loaded ${CoreClient.Cards.flatMap(x => x.cards).length} cards to database`); + const duplicateCards = CoreClient.Cards.flatMap(x => x.cards) + .filter((card, index, self) => self.findIndex(c => c.id === card.id) !== index); + + if (duplicateCards.length > 0) { + AppLogger.LogWarn("Functions/CardMetadataFunction", `Duplicate card ids found: ${duplicateCards.flatMap(x => x.id).join(", ")}`); + } + return { IsSuccess: true, }; From 302a7629127553d4cd3f06590241cda42ab20ad9 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sat, 1 Jun 2024 18:07:04 +0100 Subject: [PATCH 10/16] 0.6.0 --- .env.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 04c967b..ce664a9 100644 --- a/.env.example +++ b/.env.example @@ -7,7 +7,7 @@ # any secret values. BOT_TOKEN= -BOT_VER=0.5.2 +BOT_VER=0.6.0 BOT_AUTHOR=Vylpes BOT_OWNERID=147392775707426816 BOT_CLIENTID=682942374040961060 From cfcc8ad1008a1925026d0bb99c4afddcc557564e Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sat, 1 Jun 2024 18:09:42 +0100 Subject: [PATCH 11/16] 0.6.0 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3be07c5..bf650eb 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "card-drop", - "version": "0.5.2", + "version": "0.6.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "card-drop", - "version": "0.5.2", + "version": "0.6.0", "license": "MIT", "dependencies": { "@discordjs/rest": "^2.0.0", diff --git a/package.json b/package.json index cfd36ff..25a7c33 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "card-drop", - "version": "0.5.2", + "version": "0.6.0", "main": "./dist/bot.js", "typings": "./dist", "scripts": { From 837013835e665fb4650c95f5a90b54303bd59b47 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sun, 2 Jun 2024 15:39:24 +0100 Subject: [PATCH 12/16] Fix user being able to claim cards with a 0 balance --- src/buttonEvents/Claim.ts | 27 ++++++++++++++------------- src/buttonEvents/Reroll.ts | 16 ++++++++++++++++ src/commands/drop.ts | 16 ++++++++++++++++ 3 files changed, 46 insertions(+), 13 deletions(-) diff --git a/src/buttonEvents/Claim.ts b/src/buttonEvents/Claim.ts index e94f7cc..4f7f5ae 100644 --- a/src/buttonEvents/Claim.ts +++ b/src/buttonEvents/Claim.ts @@ -11,6 +11,7 @@ import CardConstants from "../constants/CardConstants"; export default class Claim extends ButtonEvent { public override async execute(interaction: ButtonInteraction) { if (!interaction.guild || !interaction.guildId) return; + if (!interaction.channel) return; await interaction.deferUpdate(); @@ -21,15 +22,26 @@ export default class Claim extends ButtonEvent { AppLogger.LogSilly("Button/Claim", `Parameters: cardNumber=${cardNumber}, claimId=${claimId}, droppedBy=${droppedBy}, userId=${userId}`); + const user = await User.FetchOneById(User, userId) || new User(userId, CardConstants.StartingCurrency); + + AppLogger.LogSilly("Button/Claim", `${user.Id} has ${user.Currency} currency`); + + if (!user.RemoveCurrency(CardConstants.ClaimCost)) { + await interaction.channel.send(`${interaction.user}, Not enough currency! You need ${CardConstants.ClaimCost} currency, you have ${user.Currency}!`); + return; + } + + await user.Save(User, user); + const claimed = await eClaim.FetchOneByClaimId(claimId); if (claimed) { - await interaction.reply("This card has already been claimed"); + await interaction.channel.send(`${interaction.user}, This card has already been claimed!`); return; } if (claimId == CoreClient.ClaimId && userId != droppedBy) { - await interaction.reply("The latest dropped card can only be claimed by the user who dropped it"); + await interaction.channel.send(`${interaction.user}, The latest dropped card can only be claimed by the user who dropped it!`); return; } @@ -43,17 +55,6 @@ export default class Claim extends ButtonEvent { await inventory.Save(Inventory, inventory); - const user = await User.FetchOneById(User, userId) || new User(userId, CardConstants.StartingCurrency); - - AppLogger.LogSilly("Button/Claim", `${user.Id} has ${user.Currency} currency`); - - if (!user.RemoveCurrency(CardConstants.ClaimCost)) { - await interaction.reply(`Not enough currency! You need 10 currency, you have ${user.Currency}`); - return; - } - - await user.Save(User, user); - const claim = new eClaim(claimId); claim.SetInventory(inventory); diff --git a/src/buttonEvents/Reroll.ts b/src/buttonEvents/Reroll.ts index c271a3a..c55aedf 100644 --- a/src/buttonEvents/Reroll.ts +++ b/src/buttonEvents/Reroll.ts @@ -8,6 +8,8 @@ import Config from "../database/entities/app/Config"; import CardDropHelperMetadata from "../helpers/CardDropHelperMetadata"; import path from "path"; import AppLogger from "../client/appLogger"; +import User from "../database/entities/app/User"; +import CardConstants from "../constants/CardConstants"; export default class Reroll extends ButtonEvent { public override async execute(interaction: ButtonInteraction) { @@ -23,6 +25,20 @@ export default class Reroll extends ButtonEvent { return; } + let user = await User.FetchOneById(User, interaction.user.id); + + if (!user) { + user = new User(interaction.user.id, CardConstants.StartingCurrency); + await user.Save(User, user); + + AppLogger.LogInfo("Commands/Drop", `New user (${interaction.user.id}) saved to the database`); + } + + if (user.Currency < CardConstants.ClaimCost) { + await interaction.reply(`Not enough currency! You need ${CardConstants.ClaimCost} currency, you have ${user.Currency}!`); + return; + } + const randomCard = CardDropHelperMetadata.GetRandomCard(); if (!randomCard) { diff --git a/src/commands/drop.ts b/src/commands/drop.ts index 7a91042..ab6c339 100644 --- a/src/commands/drop.ts +++ b/src/commands/drop.ts @@ -8,6 +8,8 @@ import Config from "../database/entities/app/Config"; import CardDropHelperMetadata from "../helpers/CardDropHelperMetadata"; import path from "path"; import AppLogger from "../client/appLogger"; +import User from "../database/entities/app/User"; +import CardConstants from "../constants/CardConstants"; export default class Drop extends Command { constructor() { @@ -31,6 +33,20 @@ export default class Drop extends Command { return; } + let user = await User.FetchOneById(User, interaction.user.id); + + if (!user) { + user = new User(interaction.user.id, CardConstants.StartingCurrency); + await user.Save(User, user); + + AppLogger.LogInfo("Commands/Drop", `New user (${interaction.user.id}) saved to the database`); + } + + if (user.Currency < CardConstants.ClaimCost) { + await interaction.reply(`Not enough currency! You need ${CardConstants.ClaimCost} currency, you have ${user.Currency}!`); + return; + } + const randomCard = CardDropHelperMetadata.GetRandomCard(); if (!randomCard) { From f12bb11ffbb83cc099242d95cc89eb89abd46d7a Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sun, 2 Jun 2024 16:05:05 +0100 Subject: [PATCH 13/16] Fix a user being able to make a trade with themself --- src/commands/trade.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/commands/trade.ts b/src/commands/trade.ts index 60f9033..3324128 100644 --- a/src/commands/trade.ts +++ b/src/commands/trade.ts @@ -36,6 +36,11 @@ export default class Trade extends Command { AppLogger.LogSilly("Commands/Trade", `Parameters: user=${user.id}, give=${give.value}, receive=${receive.value}`); + if (interaction.user.id == user.id) { + await interaction.reply("You can not create a trade with yourself."); + return; + } + const giveItemEntity = await Inventory.FetchOneByCardNumberAndUserId(interaction.user.id, give.value!.toString()); const receiveItemEntity = await Inventory.FetchOneByCardNumberAndUserId(user.id, receive.value!.toString()); From ebec66607f88ee3221c1ff0bbabc3bc6a4dddec2 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sun, 2 Jun 2024 16:11:05 +0100 Subject: [PATCH 14/16] 0.6.1 --- .env.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.example b/.env.example index ce664a9..dc6f5de 100644 --- a/.env.example +++ b/.env.example @@ -7,7 +7,7 @@ # any secret values. BOT_TOKEN= -BOT_VER=0.6.0 +BOT_VER=0.6.1 BOT_AUTHOR=Vylpes BOT_OWNERID=147392775707426816 BOT_CLIENTID=682942374040961060 From 5c6c0e65c3586b01a34786d5a110be835af96402 Mon Sep 17 00:00:00 2001 From: Ethan Lane Date: Sun, 2 Jun 2024 16:16:19 +0100 Subject: [PATCH 15/16] 0.6.1 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index bf650eb..83153ed 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "card-drop", - "version": "0.6.0", + "version": "0.6.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "card-drop", - "version": "0.6.0", + "version": "0.6.1", "license": "MIT", "dependencies": { "@discordjs/rest": "^2.0.0", diff --git a/package.json b/package.json index 25a7c33..ec102f9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "card-drop", - "version": "0.6.0", + "version": "0.6.1", "main": "./dist/bot.js", "typings": "./dist", "scripts": { From b30e2f4533591f42a76d824241e0c5f82581b912 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Sun, 2 Jun 2024 23:02:05 +0000 Subject: [PATCH 16/16] Update dependency discord.js to v14.15.3 --- package-lock.json | 122 ++++++++++++++++++++++++---------------------- 1 file changed, 64 insertions(+), 58 deletions(-) diff --git a/package-lock.json b/package-lock.json index 83153ed..dca33d1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -732,19 +732,24 @@ } }, "node_modules/@discordjs/builders": { - "version": "1.7.0", + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/@discordjs/builders/-/builders-1.8.2.tgz", + "integrity": "sha512-6wvG3QaCjtMu0xnle4SoOIeFB4y6fKMN6WZfy3BMKJdQQtPLik8KGzDwBVL/+wTtcE/ZlFjgEk74GublyEVZ7g==", "license": "Apache-2.0", "dependencies": { - "@discordjs/formatters": "^0.3.3", - "@discordjs/util": "^1.0.2", - "@sapphire/shapeshift": "^3.9.3", - "discord-api-types": "0.37.61", + "@discordjs/formatters": "^0.4.0", + "@discordjs/util": "^1.1.0", + "@sapphire/shapeshift": "^3.9.7", + "discord-api-types": "0.37.83", "fast-deep-equal": "^3.1.3", - "ts-mixer": "^6.0.3", + "ts-mixer": "^6.0.4", "tslib": "^2.6.2" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/@discordjs/collection": { @@ -760,13 +765,18 @@ } }, "node_modules/@discordjs/formatters": { - "version": "0.3.3", + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/@discordjs/formatters/-/formatters-0.4.0.tgz", + "integrity": "sha512-fJ06TLC1NiruF35470q3Nr1bi95BdvKFAF+T5bNfZJ4bNdqZ3VZ+Ttg6SThqTxm6qumSG3choxLBHMC69WXNXQ==", "license": "Apache-2.0", "dependencies": { - "discord-api-types": "0.37.61" + "discord-api-types": "0.37.83" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/@discordjs/rest": { @@ -792,22 +802,6 @@ "url": "https://github.com/discordjs/discord.js?sponsor" } }, - "node_modules/@discordjs/rest/node_modules/@sapphire/snowflake": { - "version": "3.5.3", - "resolved": "https://registry.npmjs.org/@sapphire/snowflake/-/snowflake-3.5.3.tgz", - "integrity": "sha512-jjmJywLAFoWeBi1W7994zZyiNWPIiqRRNAmSERxyg93xRGzNYvGjlZ0gR6x0F4gPRi2+0O6S71kOZYyr3cxaIQ==", - "license": "MIT", - "engines": { - "node": ">=v14.0.0", - "npm": ">=7.0.0" - } - }, - "node_modules/@discordjs/rest/node_modules/discord-api-types": { - "version": "0.37.83", - "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.37.83.tgz", - "integrity": "sha512-urGGYeWtWNYMKnYlZnOnDHm8fVRffQs3U0SpE8RHeiuLKb/u92APS8HoQnPTFbnXmY1vVnXjXO4dOxcAn3J+DA==", - "license": "MIT" - }, "node_modules/@discordjs/util": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@discordjs/util/-/util-1.1.0.tgz", @@ -821,21 +815,26 @@ } }, "node_modules/@discordjs/ws": { - "version": "1.0.2", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@discordjs/ws/-/ws-1.1.1.tgz", + "integrity": "sha512-PZ+vLpxGCRtmr2RMkqh8Zp+BenUaJqlS6xhgWKEZcgC/vfHLEzpHtKkB0sl3nZWpwtcKk6YWy+pU3okL2I97FA==", "license": "Apache-2.0", "dependencies": { - "@discordjs/collection": "^2.0.0", - "@discordjs/rest": "^2.1.0", - "@discordjs/util": "^1.0.2", - "@sapphire/async-queue": "^1.5.0", - "@types/ws": "^8.5.9", - "@vladfrangu/async_event_emitter": "^2.2.2", - "discord-api-types": "0.37.61", + "@discordjs/collection": "^2.1.0", + "@discordjs/rest": "^2.3.0", + "@discordjs/util": "^1.1.0", + "@sapphire/async-queue": "^1.5.2", + "@types/ws": "^8.5.10", + "@vladfrangu/async_event_emitter": "^2.2.4", + "discord-api-types": "0.37.83", "tslib": "^2.6.2", - "ws": "^8.14.2" + "ws": "^8.16.0" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/@discordjs/ws/node_modules/@types/ws": { @@ -1715,19 +1714,22 @@ } }, "node_modules/@sapphire/shapeshift": { - "version": "3.9.3", + "version": "3.9.7", + "resolved": "https://registry.npmjs.org/@sapphire/shapeshift/-/shapeshift-3.9.7.tgz", + "integrity": "sha512-4It2mxPSr4OGn4HSQWGmhFMsNFGfFVhWeRPCRwbH972Ek2pzfGRZtb0pJ4Ze6oIzcyh2jw7nUDa6qGlWofgd9g==", "license": "MIT", "dependencies": { "fast-deep-equal": "^3.1.3", "lodash": "^4.17.21" }, "engines": { - "node": ">=v14.0.0", - "npm": ">=7.0.0" + "node": ">=v16" } }, "node_modules/@sapphire/snowflake": { - "version": "3.5.1", + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/@sapphire/snowflake/-/snowflake-3.5.3.tgz", + "integrity": "sha512-jjmJywLAFoWeBi1W7994zZyiNWPIiqRRNAmSERxyg93xRGzNYvGjlZ0gR6x0F4gPRi2+0O6S71kOZYyr3cxaIQ==", "license": "MIT", "engines": { "node": ">=v14.0.0", @@ -2009,13 +2011,6 @@ "resolved": "https://registry.npmjs.org/@types/uuid/-/uuid-9.0.8.tgz", "integrity": "sha512-jg+97EGIcY9AGHJJRaaPVgetKDsrTgbRjQ5Msgjh/DQKEFl0DtyRr/VCOyD1T2R1MNeWPK/u7JoGhlDZnKBAfA==" }, - "node_modules/@types/ws": { - "version": "8.5.9", - "license": "MIT", - "dependencies": { - "@types/node": "*" - } - }, "node_modules/@types/yargs": { "version": "17.0.32", "license": "MIT", @@ -4241,34 +4236,41 @@ } }, "node_modules/discord-api-types": { - "version": "0.37.61", + "version": "0.37.83", + "resolved": "https://registry.npmjs.org/discord-api-types/-/discord-api-types-0.37.83.tgz", + "integrity": "sha512-urGGYeWtWNYMKnYlZnOnDHm8fVRffQs3U0SpE8RHeiuLKb/u92APS8HoQnPTFbnXmY1vVnXjXO4dOxcAn3J+DA==", "license": "MIT" }, "node_modules/discord.js": { - "version": "14.14.1", + "version": "14.15.3", + "resolved": "https://registry.npmjs.org/discord.js/-/discord.js-14.15.3.tgz", + "integrity": "sha512-/UJDQO10VuU6wQPglA4kz2bw2ngeeSbogiIPx/TsnctfzV/tNf+q+i1HlgtX1OGpeOBpJH9erZQNO5oRM2uAtQ==", "license": "Apache-2.0", "dependencies": { - "@discordjs/builders": "^1.7.0", + "@discordjs/builders": "^1.8.2", "@discordjs/collection": "1.5.3", - "@discordjs/formatters": "^0.3.3", - "@discordjs/rest": "^2.1.0", - "@discordjs/util": "^1.0.2", - "@discordjs/ws": "^1.0.2", - "@sapphire/snowflake": "3.5.1", - "@types/ws": "8.5.9", - "discord-api-types": "0.37.61", + "@discordjs/formatters": "^0.4.0", + "@discordjs/rest": "^2.3.0", + "@discordjs/util": "^1.1.0", + "@discordjs/ws": "^1.1.1", + "@sapphire/snowflake": "3.5.3", + "discord-api-types": "0.37.83", "fast-deep-equal": "3.1.3", "lodash.snakecase": "4.1.1", "tslib": "2.6.2", - "undici": "5.27.2", - "ws": "8.14.2" + "undici": "6.13.0" }, "engines": { "node": ">=16.11.0" + }, + "funding": { + "url": "https://github.com/discordjs/discord.js?sponsor" } }, "node_modules/discord.js/node_modules/@discordjs/collection": { "version": "1.5.3", + "resolved": "https://registry.npmjs.org/@discordjs/collection/-/collection-1.5.3.tgz", + "integrity": "sha512-SVb428OMd3WO1paV3rm6tSjM4wC+Kecaa1EUGX7vc6/fddvw/6lg90z4QtCqm21zvVe92vMMDt9+DkIvjXImQQ==", "license": "Apache-2.0", "engines": { "node": ">=16.11.0" @@ -10966,7 +10968,9 @@ } }, "node_modules/ts-mixer": { - "version": "6.0.3", + "version": "6.0.4", + "resolved": "https://registry.npmjs.org/ts-mixer/-/ts-mixer-6.0.4.tgz", + "integrity": "sha512-ufKpbmrugz5Aou4wcr5Wc1UUFWOLhq+Fm6qa6P0w0K5Qw2yhaUoiWszhCVuNQyNwrlGiscHOmqYoAox1PtvgjA==", "license": "MIT" }, "node_modules/tslib": { @@ -11657,7 +11661,9 @@ } }, "node_modules/ws": { - "version": "8.14.2", + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.0.tgz", + "integrity": "sha512-uJq6108EgZMAl20KagGkzCKfMEjxmKvZHG7Tlq0Z6nOky7YF7aq4mOx6xK8TJ/i1LeK4Qus7INktacctDgY8Ow==", "license": "MIT", "engines": { "node": ">=10.0.0"