Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

Commit

Permalink
fix MHz view
Browse files Browse the repository at this point in the history
  • Loading branch information
MHSanaei committed May 25, 2023
1 parent 15211f8 commit 6a7c371
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions web/assets/js/util/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@ function sizeFormat(size) {
}

function cpuSpeedFormat(speed) {
const GHz = speed / 1000;
return GHz.toFixed(2) + " GHz";
if (speed > 1000) {
const GHz = speed / 1000;
return GHz.toFixed(2) + " GHz";
} else {
return speed.toFixed(2) + " MHz";
}
}

function cpuCoreFormat(cores) {
Expand Down

0 comments on commit 6a7c371

Please sign in to comment.