diff options
Diffstat (limited to 'build/cleaners/skyblock/profile.js')
-rw-r--r-- | build/cleaners/skyblock/profile.js | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/build/cleaners/skyblock/profile.js b/build/cleaners/skyblock/profile.js index ef90ce8..ba2c030 100644 --- a/build/cleaners/skyblock/profile.js +++ b/build/cleaners/skyblock/profile.js @@ -31,9 +31,19 @@ async function cleanSkyblockProfileResponse(data, options) { for (const memberUUID in data.members) { const memberRaw = data.members[memberUUID]; memberRaw.uuid = memberUUID; - promises.push(member_1.cleanSkyBlockProfileMemberResponse(memberRaw, ['stats', (options === null || options === void 0 ? void 0 : options.mainMemberUuid) === memberUUID ? 'inventories' : undefined])); + promises.push(member_1.cleanSkyBlockProfileMemberResponse(memberRaw, [ + !(options === null || options === void 0 ? void 0 : options.basic) ? 'stats' : undefined, + (options === null || options === void 0 ? void 0 : options.mainMemberUuid) === memberUUID ? 'inventories' : undefined + ])); } const cleanedMembers = (await Promise.all(promises)).filter(m => m !== null && m !== undefined); + if (options === null || options === void 0 ? void 0 : options.basic) { + return { + uuid: data.profile_id, + name: data.cute_name, + members: cleanedMembers, + }; + } const memberMinions = []; for (const member of cleanedMembers) { memberMinions.push(member.minions); |