Skip to content

Commit

Permalink
Minor change
Browse files Browse the repository at this point in the history
  • Loading branch information
ale5000-git committed Jul 22, 2024
1 parent bb0b96c commit 04c35c6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion includes/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ do_AJAX_post_request_and_output_response_to_stdout()
"${WGET_CMD:?}" -q -O '-' "${@}" --post-data "${_post_data?}" -- "${_url:?}"
}

# 1 => JSON response; 2 => Field to get
# 1 => JSON response; 2 => Field to retrieve
parse_JSON_response()
{
printf '%s\n' "${1:?}" | grep -o -m 1 -E -e "\"${2:?}\""'\s*:\s*"[^"]+' | cut -d ':' -f '2-' -s | grep -o -e '".*' | cut -c '2-'
Expand Down

0 comments on commit 04c35c6

Please sign in to comment.