Disk: Fixed error in output
This commit is contained in:
parent
6ec9d163e2
commit
cc9c3a4573
1 changed files with 2 additions and 1 deletions
3
neofetch
3
neofetch
|
@ -1697,7 +1697,8 @@ get_disk() {
|
||||||
# Create an array called 'disks' where each element is a separate line from
|
# Create an array called 'disks' where each element is a separate line from
|
||||||
# df's output. We then unset the first element which removes the column titles.
|
# df's output. We then unset the first element which removes the column titles.
|
||||||
IFS=$'\n'
|
IFS=$'\n'
|
||||||
disks=($(df "${df_flags[@]}" "${disk_show[@]:-/}")) && unset 'disks[0]'
|
disks=($(df "${df_flags[@]}" "${disk_show[@]:-/}" 2>/dev/null))
|
||||||
|
unset 'disks[0]'
|
||||||
IFS="$old_ifs"
|
IFS="$old_ifs"
|
||||||
|
|
||||||
# Stop here if 'df' fails to print disk info.
|
# Stop here if 'df' fails to print disk info.
|
||||||
|
|
Loading…
Reference in a new issue