bash: Fix bug in brew update checking code during login