Skip to content

Commit

Permalink
Add profile name to /skyblock/profile/ endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
SomeRandom-WhoLikesCode authored and ChristianDobbie committed Jan 10, 2022
1 parent 06c5955 commit fe35a7c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion store/buildSkyBlockProfiles.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,13 @@ async function buildProfile(uuid, id = null) {
}

// eslint-disable-next-line arrow-body-style
return cachedFunction(`skyblock_profile:${profile_id}`, async () => {
returned_Profile = await cachedFunction(`skyblock_profile:${profile_id}`, async () => {
// insertSkyBlockProfile(profile);

return getProfileData(profile_id);
}, { cacheDuration: 600 });
returned_Profile["cute_name"] = profiles[profile_id].cute_name.toLowerCase() //add profile name to the end of the profile
return returned_Profile //return appended profile object
}

module.exports = {
Expand Down

0 comments on commit fe35a7c

Please sign in to comment.