From 80e3af2acca74fa34ca6ae8577da0d4b45b72fbb Mon Sep 17 00:00:00 2001 From: slweeb <91897291+slweeb@users.noreply.github.com> Date: Sat, 5 Oct 2024 18:54:04 -0400 Subject: [PATCH] Update betterStats.js --- mods/betterStats.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/betterStats.js b/mods/betterStats.js index 3c043b10..2cb49bdb 100644 --- a/mods/betterStats.js +++ b/mods/betterStats.js @@ -26,7 +26,7 @@ function updateStatsNew() { if (pixelMap[mousePos.x] != undefined) { var currentPixel = pixelMap[mousePos.x][mousePos.y]; if (currentPixel != undefined) { - stats += "Elem:" + (elements[currentPixel.element].name || currentPixel.element).toUpperCase() + ""; + stats += "Elem:" + (elements[currentPixel.element].name || currentPixel.element).toString().toUpperCase() + ""; stats += "Temp:" + formatTemp(currentPixel.temp) + ""; if (currentPixel.charge) { stats += "C" + currentPixel.charge + ""; @@ -49,7 +49,7 @@ function updateStatsNew() { } // If the view is not null, show the view in all caps if (view != null) { - stats += "" + viewKey[view].toUpperCase() + ""; + stats += "" + viewKey[view].toString().toUpperCase() + ""; } statsDiv.innerHTML = stats; }