bgnotify: use $2 in preexec hook if $1 is empty

Fixes #5803
pull/8552/head
Marc Cornellà 2020-09-28 12:09:20 +02:00 committed by GitHub
parent 765966606d
commit 53259f628b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -53,7 +53,7 @@ bgnotify () { ## args: (title, subtitle)
bgnotify_begin() {
bgnotify_timestamp=$EPOCHSECONDS
bgnotify_lastcmd="$1"
bgnotify_lastcmd="${1:-$2}"
bgnotify_windowid=$(currentWindowId)
}