Browse Source

Update synology_dsm.sh

Split "[ && ]" into "[ ] && [ ]" to make ShellCheck happy
pull/4646/head
Martin Arndt 1 year ago
committed by GitHub
parent
commit
0c9e4f67a8
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      deploy/synology_dsm.sh

2
deploy/synology_dsm.sh

@ -145,7 +145,7 @@ synology_dsm_deploy() {
token=$(echo "$response" | grep "synotoken" | sed -n 's/.*"synotoken" *: *"\([^"]*\).*/\1/p') token=$(echo "$response" | grep "synotoken" | sed -n 's/.*"synotoken" *: *"\([^"]*\).*/\1/p')
_debug "Session ID" "$sid" _debug "Session ID" "$sid"
_debug SynoToken "$token" _debug SynoToken "$token"
if [ -z "$SYNO_DID" && -z "$SYNO_Device_ID" ] || [ -z "$sid" ] || [ -z "$token" ]; then
if [ -z "$SYNO_DID" ] && [ -z "$SYNO_Device_ID" ] || [ -z "$sid" ] || [ -z "$token" ]; then
_err "Unable to authenticate to $_base_url - check your username & password." _err "Unable to authenticate to $_base_url - check your username & password."
_err "If two-factor authentication is enabled for the user, set SYNO_Device_ID." _err "If two-factor authentication is enabled for the user, set SYNO_Device_ID."
return 1 return 1

Loading…
Cancel
Save