diff options
author | mat <27899617+mat-1@users.noreply.github.com> | 2021-02-20 22:41:31 -0600 |
---|---|---|
committer | mat <27899617+mat-1@users.noreply.github.com> | 2021-02-20 22:41:31 -0600 |
commit | 892cb58ceddb2009f6c1c32ad75e1a7bec5ea06f (patch) | |
tree | 86dd519078e489994009162824e575f47b7ffd9e /src | |
parent | 74c078392c46405a8432309c8672dc09642956d6 (diff) | |
download | skyblock-api-892cb58ceddb2009f6c1c32ad75e1a7bec5ea06f.tar.gz skyblock-api-892cb58ceddb2009f6c1c32ad75e1a7bec5ea06f.tar.bz2 skyblock-api-892cb58ceddb2009f6c1c32ad75e1a7bec5ea06f.zip |
add "first_join" to `player`
Diffstat (limited to 'src')
-rw-r--r-- | src/cleaners/player.ts | 2 | ||||
-rw-r--r-- | src/cleaners/socialmedia.ts | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/cleaners/player.ts b/src/cleaners/player.ts index f4cbb18..d23fe29 100644 --- a/src/cleaners/player.ts +++ b/src/cleaners/player.ts @@ -14,6 +14,7 @@ export interface CleanPlayer extends CleanBasicPlayer { rank: CleanRank socials: CleanSocialMedia profiles?: CleanBasicProfile[] + first_join: number } export async function cleanPlayerResponse(data: HypixelPlayer): Promise<CleanPlayer> { @@ -23,6 +24,7 @@ export async function cleanPlayerResponse(data: HypixelPlayer): Promise<CleanPla username: data.displayname, rank: cleanRank(data), socials: cleanSocialMedia(data), + first_join: data.firstLogin / 1000, profiles: cleanPlayerSkyblockProfiles(data.stats?.SkyBlock?.profiles) } } diff --git a/src/cleaners/socialmedia.ts b/src/cleaners/socialmedia.ts index c7ab7ef..a4ece58 100644 --- a/src/cleaners/socialmedia.ts +++ b/src/cleaners/socialmedia.ts @@ -1,5 +1,3 @@ -import { HypixelPlayerSocialMedia } from "../hypixelApi"; - export interface CleanSocialMedia { discord: string | null forums: string | null |