Clean excess whitespace from CPU model name

Added one line to clean excess whitespace from the returned CPU model name, just before unnecessary patterns are removed and the name is returned. See issue #68
pull/86/head
RedBearAK 2020-08-23 21:56:28 -08:00 committed by GitHub
parent 7806d6f66b
commit 0115bb68f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -4095,6 +4095,8 @@ def get_cpu_name() -> str:
elif "CPU" in name and not nlist[0] == "CPU":
name = nlist[nlist.index("CPU")-1]
name = " ".join(name.split())
return name.replace("Processor ", "").replace("CPU ", "").replace("(R)", "").replace("(TM)", "").replace("Intel ", "")
def create_box(x: int = 0, y: int = 0, width: int = 0, height: int = 0, title: str = "", title2: str = "", line_color: Color = None, title_color: Color = None, fill: bool = True, box = None) -> str: