diff options
author | mat <github@matdoes.dev> | 2022-05-21 16:25:36 -0500 |
---|---|---|
committer | mat <github@matdoes.dev> | 2022-05-21 16:25:36 -0500 |
commit | bd37b154913ed7c75abe08ec6a66945849f705be (patch) | |
tree | a76b4ba4fa421714b756bdd1064539ae0a3577c1 /src/cleaners/skyblock/essence.ts | |
parent | 8582958e7f3764e47a49667c57805400643b005c (diff) | |
download | skyblock-api-bd37b154913ed7c75abe08ec6a66945849f705be.tar.gz skyblock-api-bd37b154913ed7c75abe08ec6a66945849f705be.tar.bz2 skyblock-api-bd37b154913ed7c75abe08ec6a66945849f705be.zip |
rename essence value to amount
Diffstat (limited to 'src/cleaners/skyblock/essence.ts')
-rw-r--r-- | src/cleaners/skyblock/essence.ts | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/cleaners/skyblock/essence.ts b/src/cleaners/skyblock/essence.ts index 4af94fb..19f43c1 100644 --- a/src/cleaners/skyblock/essence.ts +++ b/src/cleaners/skyblock/essence.ts @@ -1,9 +1,8 @@ import typedHypixelApi from 'typed-hypixel-api' -import * as constants from '../../constants.js' interface EssenceType { id: string - value: number + amount: number } export interface Essence { @@ -13,11 +12,11 @@ export interface Essence { export function cleanEssence(data: typedHypixelApi.SkyBlockProfileMember): Essence { const essences: EssenceType[] = [] - for (const [id, value] of Object.entries(data ?? {})) { + for (const [id, amount] of Object.entries(data ?? {})) { if (id.startsWith('essence_')) { essences.push({ id: id.replace(/^essence_/, ''), - value: value ?? 0, + amount: amount ?? 0, }) } } |