aboutsummaryrefslogtreecommitdiff
path: root/src/cleaners
diff options
context:
space:
mode:
Diffstat (limited to 'src/cleaners')
-rw-r--r--src/cleaners/rank.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cleaners/rank.ts b/src/cleaners/rank.ts
index 0a3a4a7..0e17a17 100644
--- a/src/cleaners/rank.ts
+++ b/src/cleaners/rank.ts
@@ -37,12 +37,12 @@ export function cleanRank({
color = minecraftColorCodes[colored.match(/§./)[0][1]]
name = colored.replace(/§./g, '').replace(/[\[\]]/g, '')
} else {
- if (monthlyPackageRank !== 'NONE')
+ if (monthlyPackageRank && monthlyPackageRank !== 'NONE')
name = monthlyPackageRank
else
name = rank
- || newPackageRank?.replace('_PLUS', '+')
- || packageRank?.replace('_PLUS', '+')
+ ?? newPackageRank?.replace('_PLUS', '+')
+ ?? packageRank?.replace('_PLUS', '+')
// MVP++ is called Superstar for some reason
if (name === 'SUPERSTAR') name = 'MVP++'