mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-16 19:43:29 +01:00
Attempting forceFetchUser callback
This commit is contained in:
@@ -8,6 +8,7 @@ export default class Cache extends Array {
|
||||
super();
|
||||
this[discrimS] = discrim || "id";
|
||||
this[discrimCacheS] = {};
|
||||
this.limit = limit;
|
||||
}
|
||||
|
||||
get(key, value) {
|
||||
@@ -65,7 +66,7 @@ export default class Cache extends Array {
|
||||
}
|
||||
|
||||
add(data) {
|
||||
var cacheKey = this[discrimS] === "id" ? data.id : data[this[discrimS]];
|
||||
var cacheKey = data[this[discrimS]];
|
||||
if (this[discrimCacheS][cacheKey]) {
|
||||
return this[discrimCacheS][cacheKey];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user