mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-21 21:30:09 +00:00
fix(lib): make opts local in omz_urlencode to fix scoping bug
Fixes error message when using zplug, due to $opts having been declared as an associative array: omz_urlencode:2: bad set of key/value pairs for associative array Fixes #9429
This commit is contained in:
parent
fa780867d9
commit
a3e0f4f2af
1 changed files with 1 additions and 0 deletions
|
@ -134,6 +134,7 @@ zmodload zsh/langinfo
|
||||||
# -P causes spaces to be encoded as '%20' instead of '+'
|
# -P causes spaces to be encoded as '%20' instead of '+'
|
||||||
function omz_urlencode() {
|
function omz_urlencode() {
|
||||||
emulate -L zsh
|
emulate -L zsh
|
||||||
|
local -a opts
|
||||||
zparseopts -D -E -a opts r m P
|
zparseopts -D -E -a opts r m P
|
||||||
|
|
||||||
local in_str=$1
|
local in_str=$1
|
||||||
|
|
Loading…
Reference in a new issue