Skip to content

Commit

Permalink
Fix: Account stats showing 1 orders when item count was above 999
Browse files Browse the repository at this point in the history
  • Loading branch information
FMaz008 committed Nov 18, 2024
1 parent c106de2 commit 41ee8fe
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion scripts/bootloader.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,9 @@ function displayAccountDataEvaluationMetrics() {
parseFloat(document.querySelector("#vvp-perc-reviewed-metric-display strong").innerText)
);
if (percent > 0) {
const count = parseInt(document.querySelector("#vvp-num-reviewed-metric-display strong").innerText);
const count = parseInt(
document.querySelector("#vvp-num-reviewed-metric-display strong").innerText.replace(/,/g, "")
);
const orderCount = Math.round((count / percent) * 100);
const orderMin = Math.min(Math.ceil((count / (percent + 0.5)) * 100), orderCount);
const orderMax = Math.max(Math.floor((count / (percent - 0.5)) * 100), orderCount);
Expand Down

0 comments on commit 41ee8fe

Please sign in to comment.