From 6cb184acafe943a007b6c8894b0c82eb01cadc41 Mon Sep 17 00:00:00 2001 From: TheMightyd7 Date: Tue, 31 Oct 2023 23:49:16 -0400 Subject: [PATCH] Display a reason from server when leaderboard is disabled --- scripts/leaderboard.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/leaderboard.js b/scripts/leaderboard.js index a46a6d9..e76597c 100644 --- a/scripts/leaderboard.js +++ b/scripts/leaderboard.js @@ -80,6 +80,9 @@ function getPurchases(userInfo) { leaderboard.appendChild(leaderboardTable); } else { leaderboard.innerHTML = `

Web access to the leaderboard is disabled.

`; + document.getElementById('footer-text').innerText = data.hasOwnProperty('message') + ? data.message + : 'Access to the leaderboard has been disabled by a club officer.'; } }) .catch((error) => {