aboutsummaryrefslogtreecommitdiff
path: root/src/cleaners/skyblock
diff options
context:
space:
mode:
Diffstat (limited to 'src/cleaners/skyblock')
-rw-r--r--src/cleaners/skyblock/profiles.ts4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cleaners/skyblock/profiles.ts b/src/cleaners/skyblock/profiles.ts
index f046e22..519c6d5 100644
--- a/src/cleaners/skyblock/profiles.ts
+++ b/src/cleaners/skyblock/profiles.ts
@@ -20,7 +20,9 @@ export function cleanPlayerSkyblockProfiles(rawProfiles: HypixelPlayerStatsSkyBl
}
/** Convert an array of raw profiles into clean profiles */
-export async function cleanSkyblockProfilesResponse(data: typedHypixelApi.SkyBlockProfilesResponse['profiles']): Promise<CleanFullProfile[]> {
+export async function cleanSkyblockProfilesResponse(data: typedHypixelApi.SkyBlockProfilesResponse['profiles']): Promise<CleanFullProfile[] | null> {
+ if (data === null) return null
+
const promises: Promise<CleanFullProfile | null>[] = []
for (const profile of data) {
promises.push(cleanSkyblockProfileResponse(profile))