diff --git a/neofetch b/neofetch index 9929c1ec..eccb03cb 100755 --- a/neofetch +++ b/neofetch @@ -1538,8 +1538,13 @@ getresolution () { awk '/Resolution:/ {printf $2"x"$4" @ "$6"Hz, "}')" fi - [ "$refresh_rate" == "off" ] || [ "${resolution// * @ }" == "0Hz" ] && \ - resolution="${resolution// @ *[0-9]Hz}" + if [ "$refresh_rate" == "off" ]; then + resolution="${resolution// @ [0-9][0-9]Hz}" + resolution="${resolution// @ [0-9][0-9][0-9]Hz}" + fi + + [[ "$resolution" =~ "0Hz" ]] && \ + resolution="${resolution// @ 0Hz}" ;; "Windows")