mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 08:33:30 +01:00
refactor(Managers): rename add to _add (#6060)
This commit is contained in:
@@ -27,7 +27,7 @@ class ThreadManager extends CachedManager {
|
||||
* @name ThreadManager#cache
|
||||
*/
|
||||
|
||||
add(thread) {
|
||||
_add(thread) {
|
||||
const existing = this.cache.get(thread.id);
|
||||
if (existing) return existing;
|
||||
this.cache.set(thread.id, thread);
|
||||
@@ -234,7 +234,7 @@ class ThreadManager extends CachedManager {
|
||||
|
||||
_mapThreads(rawThreads, cache) {
|
||||
const threads = rawThreads.threads.reduce((coll, raw) => {
|
||||
const thread = this.client.channels.add(raw, null, cache);
|
||||
const thread = this.client.channels._add(raw, null, cache);
|
||||
return coll.set(thread.id, thread);
|
||||
}, new Collection());
|
||||
// Discord sends the thread id as id in this object
|
||||
|
||||
Reference in New Issue
Block a user