diff --git a/src/js/elements/leaderboards.js b/src/js/elements/leaderboards.js
index d5caeab5f..0d9e5b516 100644
--- a/src/js/elements/leaderboards.js
+++ b/src/js/elements/leaderboards.js
@@ -3,6 +3,7 @@ import * as Notifications from "./notifications";
import * as DB from "./db";
import axiosInstance from "./axios-instance";
import * as Misc from "./misc";
+import Config, * as UpdateConfig from "./config";
let currentLeaderboard = "time_15";
@@ -183,10 +184,14 @@ function fillTable(lb, prepend) {
entry.rank === 1 ? '' : entry.rank
}
${entry.name} |
- ${entry.wpm.toFixed(
- 2
- )}
${entry.acc.toFixed(2)}% |
- ${entry.raw.toFixed(2)}
${
+ ${(Config.alwaysShowCPM
+ ? entry.wpm * 5
+ : entry.wpm
+ ).toFixed(2)}
${entry.acc.toFixed(2)}% |
+ ${(Config.alwaysShowCPM
+ ? entry.raw * 5
+ : entry.raw
+ ).toFixed(2)}
${
!entry.consistency || entry.consistency === "-"
? "-"
: entry.consistency.toFixed(2) + "%"
@@ -389,6 +394,15 @@ export function show() {
"disabled"
);
}
+ if (Config.alwaysShowCPM) {
+ $("#leaderboards table thead tr td:nth-child(3)").html(
+ 'cpm accuracy '
+ );
+ } else {
+ $("#leaderboards table thead tr td:nth-child(3)").html(
+ 'wpm accuracy '
+ );
+ }
$("#leaderboardsWrapper")
.stop(true, true)
.css("opacity", 0)
| |