upgpkg: discord-electron 0.0.39-3: fix launcher

* Fix launcher error if config variable not set but rizin is installed
* Fix typo
This commit is contained in:
Manuel 2024-01-04 22:47:25 +01:00
parent 9ce663bcc3
commit 92981e8b1f
Signed by: Manuel
GPG key ID: 4085037435E1F07A
4 changed files with 8 additions and 8 deletions

View file

@ -1,6 +1,6 @@
#!/usr/bin/env bash
set -euo pipefail
set -eo pipefail
declare -a flags
@ -19,9 +19,9 @@ if hash rizin &> /dev/null && [[ "${PATCH_KRISP}" == true ]]; then
fi
fi
if [[ -w "${flags_file}" ]]; then
if [[ -r "${flags_file}" ]]; then
# Replacing because old flag does not work
if grep -q '\--ignore-gpu-blacklist' "${flags_file}"; then
if [[ -w "${flags_file}" ]] && grep -q '\--ignore-gpu-blacklist' "${flags_file}"; then
sed -i "s|--ignore-gpu-blacklist|--ignore-gpu-blocklist|" "${flags_file}"
fi
mapfile -t < "${flags_file}"