From f111a9a1db78fbfe0737661f3c9104f52d6de945 Mon Sep 17 00:00:00 2001 From: mat Date: Tue, 1 Jun 2021 15:12:07 -0500 Subject: Revert "Revert "temporarily disable leaderboard cache"" This reverts commit 0203c2bf6d645e2f0c42fc3dc839e1320ee57c84. --- build/database.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'build/database.js') diff --git a/build/database.js b/build/database.js index 7c7d192..66bf90f 100644 --- a/build/database.js +++ b/build/database.js @@ -229,7 +229,7 @@ async function fetchMemberLeaderboardRaw(name) { }; }); fetchingRawLeaderboardNames.delete(name); - exports.cachedRawLeaderboards.set(name, leaderboardRaw); + // cachedRawLeaderboards.set(name, leaderboardRaw) return leaderboardRaw; } async function fetchProfileLeaderboardRaw(name) { @@ -262,7 +262,7 @@ async function fetchProfileLeaderboardRaw(name) { }; }); fetchingRawLeaderboardNames.delete(name); - exports.cachedRawLeaderboards.set(name, leaderboardRaw); + // cachedRawLeaderboards.set(name, leaderboardRaw) return leaderboardRaw; } /** Fetch a leaderboard that ranks members, as opposed to profiles */ @@ -448,7 +448,7 @@ async function updateDatabaseMember(member, profile) { }]) .sort((a, b) => leaderboardReverse ? a.value - b.value : b.value - a.value) .slice(0, 100); - exports.cachedRawLeaderboards.set(attributeName, newRawLeaderboard); + // cachedRawLeaderboards.set(attributeName, newRawLeaderboard) } if (_1.debug) console.debug('added member to leaderboards', member.username, leaderboardAttributes); @@ -496,7 +496,7 @@ async function updateDatabaseProfile(profile) { }]) .sort((a, b) => leaderboardReverse ? a.value - b.value : b.value - a.value) .slice(0, 100); - exports.cachedRawLeaderboards.set(attributeName, newRawLeaderboard); + // cachedRawLeaderboards.set(attributeName, newRawLeaderboard) } if (_1.debug) console.debug('added profile to leaderboards', profile.name, leaderboardAttributes); -- cgit