There are a lot of questions relating to results from upgrading to Discord.js v12, most commonly dealing with the addition of managers and having to use .cache
:
- discord.js V12 'filter' undefined
- Discord.js Issue with roles
- TypeError: member.guild.channels.get is not a function
- TypeError: message.guild.members.get is not a function
- TypeError: client.users.get is not a function discord.js V12
- bot.users.get is no longer a function?
- TypeError: message.guild.members.filter is not a function
- TypeError: message.guild.channels.filter is not a function
- discord.js TypeError: server.roles.find is not a function
- TypeError: servguild.roles.find is not a function
- TypeError: message.guild.roles.find is not a function
- TypeError: message.guild.channels.find is not a function discord.js
- Error: TypeError: message.guild.channels.find is not a function
- guild.members.forEach is not a function
- TypeError: message.member.roles.some is not a function
- TypeError: oldMember.roles.every is not a function
- TypeError: Cannot read property 'fetchMembers' of undefined
- TypeError: reaction.fetchMembers is not a function
- TypeError: Cannot read property 'add' of undefined, Discord.JS
- I can't use the code I use in version v11.6.4 I use version v12.3.1
- How to get user by id in discordjs 12?
- Discord.js TypeError: message.guild.createRole is not a function
- probably more questions…
Should there be a single canonical question, explaining the most common v12 breaking changes and linking to the updating to v12 guide, that we can mark these questions as a duplicate of?
I propose two different solutions:
- Make one of these existing questions the canonical. An existing question with a suitable, high-quality answer, such as this one, could be used so that a new question does not need to be created. However, this question may be too specific and not address some of the other changes in v12.
- Create a new question. A self-answered question could be created which addresses the main breaking changes in v12. We can then mark the other questions as duplicates of this one. This is the solution I prefer because it would be a single, high-quality question/answer that covers most of the issues from upgrading to v12, and is similar to what I did with this question on Arqade.