5cb943eea46d322542c5c2a9f54b201eddc2aa67
- Author
- Marc Cornellà <hello@mcornella.com>
- Committer
- Marc Cornellà <hello@mcornella.com>
- Date
Message
fix(lib): fix return code after expected non-zero exit code (#11524)
Fixes #11524
Diff
1diff --git a/lib/directories.zsh b/lib/directories.zsh
2index 091140626b83f39e5f98601e55bbd85deedc1bc5..9274b5f5f3969954ad81ee74d8da26d178a7e8fc 100644
3--- a/lib/directories.zsh
4+++ b/lib/directories.zsh
5@@ -8,7 +8,7 @@ setopt pushdminus
6 # to your `zshrc` before loading `oh-my-zsh.sh`
7 # to disable the following aliases and functions
8
9-zstyle -T ':omz:directories' aliases || return
10+zstyle -T ':omz:directories' aliases || return 0
11
12 alias -g ...='../..'
13 alias -g ....='../../..'
14diff --git a/lib/vcs_info.zsh b/lib/vcs_info.zsh
15index e60938c1452dd8e464366d49571a54570e3371eb..be6d32ee90ac3dc3000031c78a7bf40db00cf56b 100644
16--- a/lib/vcs_info.zsh
17+++ b/lib/vcs_info.zsh
18@@ -38,7 +38,7 @@
19 # due to malicious input as a consequence of CVE-2021-45444, which affects
20 # zsh versions from 5.0.3 to 5.8.
21 #
22-autoload -Uz +X regexp-replace VCS_INFO_formats 2>/dev/null || return
23+autoload -Uz +X regexp-replace VCS_INFO_formats 2>/dev/null || return 0
24
25 # We use $tmp here because it's already a local variable in VCS_INFO_formats
26 typeset PATCH='for tmp (base base-name branch misc revision subdir) hook_com[$tmp]="${hook_com[$tmp]//\%/%%}"'