更改 CPU Core 的匹配方式。

This commit is contained in:
Kotone Fujita^^ 2024-12-05 17:19:12 +08:00 committed by hi2hi
parent 7cf1c7ddf2
commit bcb916a03c

View File

@ -35,7 +35,7 @@ export function getCPUInfo(text) {
const companyReg = /Intel|AMD|ARM|Qualcomm|Apple|Samsung|IBM|NVIDIA/;
// eslint-disable-next-line max-len, vue/max-len
const modelReg = /Xeon|Threadripper|Athlon|Pentium|Celeron|Opteron|Phenom|Turion|Sempron|FX|A-Series|R-Series|EPYC|Ryzen/;
const coresReg = /(\d+) (Virtual|Physics) Core/;
const coresReg = /(\d+) (Virtual|Physics|Physical) Core/;
const companyMatch = text.match(companyReg);
const modelMatch = text.match(modelReg);
const coresMatch = text.match(coresReg);