Skip to content
This repository has been archived by the owner on Oct 22, 2021. It is now read-only.

Commit

Permalink
fix(mod_cpuinfo): cpu speed not displaying
Browse files Browse the repository at this point in the history
  • Loading branch information
GitSquared committed Feb 22, 2021
1 parent 5aa1232 commit eeeb7a8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/classes/cpuinfo.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class Cpuinfo {
<i id="mod_cpuinfo_temp">${(process.platform === "win32") ? data.cores : "--°C"}</i></h1>
</div>
<div>
<h1>MIN<br>
<h1>SPD<br>
<i id="mod_cpuinfo_speed_min">--GHz</i></h1>
</div>
<div>
Expand Down Expand Up @@ -153,10 +153,10 @@ class Cpuinfo {
});
}
updateCPUspeed() {
window.si.cpuCurrentspeed().then(data => {
window.si.cpu().then(data => {
try {
document.getElementById("mod_cpuinfo_speed_min").innerText = `${data.min}GHz`;
document.getElementById("mod_cpuinfo_speed_max").innerText = `${data.max}GHz`;
document.getElementById("mod_cpuinfo_speed_min").innerText = `${data.speed}GHz`;
document.getElementById("mod_cpuinfo_speed_max").innerText = `${data.speedMax}GHz`;
} catch(e) {
// See above notice
}
Expand Down

0 comments on commit eeeb7a8

Please sign in to comment.