mirror of
https://github.com/Terranom674/Piwigo_Bratonien_Tools.git
synced 2026-09-19 11:44:31 +00:00
Clear stale error detail on successful connector status
This commit is contained in:
@@ -53,7 +53,11 @@ ERROR_DETAIL=""
|
||||
|
||||
write_status() {
|
||||
local state="$1" message="$2"
|
||||
python3 - "$STATUS_FILE" "$PUBLIC_STATUS_FILE" "$state" "$message" "$AUTH_MODE" "$API_STATE" "$API_MESSAGE" "$FALLBACK_STATE" "$FALLBACK_MESSAGE" "$ERROR_DETAIL" <<'PY'
|
||||
local error_detail="$ERROR_DETAIL"
|
||||
if [[ "$state" != "error" ]]; then
|
||||
error_detail=""
|
||||
fi
|
||||
python3 - "$STATUS_FILE" "$PUBLIC_STATUS_FILE" "$state" "$message" "$AUTH_MODE" "$API_STATE" "$API_MESSAGE" "$FALLBACK_STATE" "$FALLBACK_MESSAGE" "$error_detail" <<'PY'
|
||||
import json, os, sys, tempfile, time
|
||||
(path, public_path, state, message, auth_mode, api_state, api_message,
|
||||
fallback_state, fallback_message, error_detail) = sys.argv[1:]
|
||||
|
||||
Reference in New Issue
Block a user