Skip to content

Conversation

@DuroCodes
Copy link
Contributor

fixes the deprecation warning

Warning

this also bumps discord.js to ^14.22.1, but there shouldn't be any breaking changes.

DeprecationWarning: The ready event has been renamed to clientReady to distinguish it from the gateway READY event and will only emit under that name in v15. Please use clientReady instead.
      at triggerClientReady (/Users/david/Programming/TypeScript/2910-bot/node_modules/discord.js/src/client/websocket/WebSocketManager.js:389:15)
      at checkShardsReady (/Users/david/Programming/TypeScript/2910-bot/node_modules/discord.js/src/client/websocket/WebSocketManager.js:368:10)
      at <anonymous> (/Users/david/Programming/TypeScript/2910-bot/node_modules/discord.js/src/client/websocket/WebSocketManager.js:198:16)
      at emit2 (node:events:123:31)
      at checkReady (/Users/david/Programming/TypeScript/2910-bot/node_modules/discord.js/src/client/websocket/WebSocketShard.js:184:12)
      at gotGuild (/Users/david/Programming/TypeScript/2910-bot/node_modules/discord.js/src/client/websocket/WebSocketShard.js:158:10)
      at <anonymous> (/Users/david/Programming/TypeScript/2910-bot/node_modules/discord.js/src/client/websocket/WebSocketManager.js:238:15)
      at emit (/Users/david/Programming/TypeScript/2910-bot/node_modules/@vladfrangu/async_event_emitter/dist/index.cjs:287:31)
      at emit (/Users/david/Programming/TypeScript/2910-bot/node_modules/@vladfrangu/async_event_emitter/dist/index.cjs:287:31)

@DuroCodes DuroCodes requested a review from jacoobes as a code owner September 22, 2025 01:16
@SrIzan10 SrIzan10 requested a review from Copilot September 22, 2025 05:32
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes a deprecation warning in discord.js by replacing the deprecated ready event with the new clientReady event name using the Events.ClientReady enum. It also updates the discord.js dependency to version 14.22.1 to support the new event naming.

  • Updates event listener from string literal "ready" to Events.ClientReady enum
  • Bumps discord.js dependency to version 14.22.1
  • Applies code formatting improvements throughout the ready handler

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated no comments.

File Description
src/handlers/ready.ts Updates deprecated ready event to clientReady using Events enum and applies code formatting
package.json Bumps discord.js dependency from 14.14.1 to 14.22.1

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link
Member

@SrIzan10 SrIzan10 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@SrIzan10 SrIzan10 self-requested a review September 22, 2025 05:36
Copy link
Member

@SrIzan10 SrIzan10 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think you should bump the package version through here

@jcobnolaedu
Copy link

looks good to me

Copy link
Contributor Author

@DuroCodes DuroCodes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated and bumped

@jacoobes jacoobes merged commit c67748c into sern-handler:main Sep 22, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants