aboutsummaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authormat <github@matdoes.dev>2021-05-24 18:45:35 -0500
committermat <github@matdoes.dev>2021-05-24 18:45:35 -0500
commitee30474985ca2556f931e4ffd5e3643048bea1c5 (patch)
tree381e59c2b8e5c50bf0109cb9d1c01d0b611615bf /build
parentda55f893ef3ea3c55816d36e63f11fe6509ce843 (diff)
downloadskyblock-api-ee30474985ca2556f931e4ffd5e3643048bea1c5.tar.gz
skyblock-api-ee30474985ca2556f931e4ffd5e3643048bea1c5.tar.bz2
skyblock-api-ee30474985ca2556f931e4ffd5e3643048bea1c5.zip
remove first_join from CleanPlayer
we *probably* don't need it
Diffstat (limited to 'build')
-rw-r--r--build/cleaners/player.js2
-rw-r--r--build/hypixelCached.js4
2 files changed, 5 insertions, 1 deletions
diff --git a/build/cleaners/player.js b/build/cleaners/player.js
index 4957e7a..dadb129 100644
--- a/build/cleaners/player.js
+++ b/build/cleaners/player.js
@@ -15,7 +15,7 @@ async function cleanPlayerResponse(data) {
username: data.displayname,
rank: rank_1.cleanRank(data),
socials: socialmedia_1.cleanSocialMedia(data),
- first_join: data.firstLogin / 1000,
+ // first_join: data.firstLogin / 1000,
profiles: profiles_1.cleanPlayerSkyblockProfiles((_b = (_a = data.stats) === null || _a === void 0 ? void 0 : _a.SkyBlock) === null || _b === void 0 ? void 0 : _b.profiles)
};
}
diff --git a/build/hypixelCached.js b/build/hypixelCached.js
index fcdfcf9..8dac057 100644
--- a/build/hypixelCached.js
+++ b/build/hypixelCached.js
@@ -231,6 +231,10 @@ async function fetchBasicProfiles(user) {
if (_1.debug)
console.debug('Cache miss: fetchBasicProfiles', user);
const player = await fetchPlayer(playerUuid);
+ if (!player) {
+ console.log('bruh playerUuid', playerUuid);
+ return [];
+ }
const profiles = player.profiles;
exports.basicProfilesCache.set(playerUuid, profiles);
// cache the profile names and uuids to profileNameCache because we can