File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed
Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1022,7 +1022,7 @@ cat "$TMPFILE.code"
10221022return 1
10231023fi
10241024(rm -f " $TMPFILE .code" & )
1025- response_check_refresh_token=" $( _curl --compressed " $CURL_PROGRESS " -X POST \
1025+ response_check_refresh_token=" $( curl --compressed " $CURL_PROGRESS " -X POST \
10261026--data " code=$authorization_code &client_id=$CLIENT_ID &client_secret=$CLIENT_SECRET &redirect_uri=$REDIRECT_URI %3A$server_port_check_refresh_token &grant_type=authorization_code&code_verifier=$code_challenge_check_refresh_token " " $TOKEN_URL " ) " || :
10271027_clear_line 1 1>&2
10281028refresh_token_value_check_refresh_token=" $( printf " %s\n" " $response_check_refresh_token " | _json_value refresh_token 1 1) " || { printf " %s\n" " Error: Cannot fetch refresh token, make sure the authorization code was correct." && printf " %s\n" " $response_check_refresh_token " && return 1; }
Original file line number Diff line number Diff line change @@ -995,7 +995,7 @@ cat "$TMPFILE.code"
995995return 1
996996fi
997997(rm -f " $TMPFILE .code" & )
998- response_check_refresh_token=" $( _curl --compressed " $CURL_PROGRESS " -X POST \
998+ response_check_refresh_token=" $( curl --compressed " $CURL_PROGRESS " -X POST \
999999--data " code=$authorization_code &client_id=$CLIENT_ID &client_secret=$CLIENT_SECRET &redirect_uri=$REDIRECT_URI %3A$server_port_check_refresh_token &grant_type=authorization_code&code_verifier=$code_challenge_check_refresh_token " " $TOKEN_URL " ) " || :
10001000_clear_line 1 1>&2
10011001refresh_token_value_check_refresh_token=" $( printf " %s\n" " $response_check_refresh_token " | _json_value refresh_token 1 1) " || { printf " %s\n" " Error: Cannot fetch refresh token, make sure the authorization code was correct." && printf " %s\n" " $response_check_refresh_token " && return 1; }
Original file line number Diff line number Diff line change @@ -398,12 +398,12 @@ EOF
398398 (rm -f " ${TMPFILE} .code" & )
399399
400400 # https://developers.google.com/identity/protocols/oauth2/native-app#handlingresponse
401- response_check_refresh_token=" $( _curl --compressed " ${CURL_PROGRESS} " -X POST \
401+ response_check_refresh_token=" $( curl --compressed " ${CURL_PROGRESS} " -X POST \
402402 --data " code=${authorization_code} &client_id=${CLIENT_ID} &client_secret=${CLIENT_SECRET} &redirect_uri=${REDIRECT_URI} %3A${server_port_check_refresh_token} &grant_type=authorization_code&code_verifier=${code_challenge_check_refresh_token} " " ${TOKEN_URL} " ) " || :
403403 _clear_line 1 1>&2
404404
405405 refresh_token_value_check_refresh_token=" $( printf " %s\n" " ${response_check_refresh_token} " | _json_value refresh_token 1 1) " ||
406- { printf " %s\n" " Error: Cannot fetch refresh token, make sure the authorization code was correct ." && printf " %s\n" " ${response_check_refresh_token} " && return 1; }
406+ { printf " %s\n" " Error: Code was not fetched properly , here is some info that maybe helpful. ." && printf " %s\n" " ${response_check_refresh_token} " && return 1; }
407407
408408 _set_value direct REFRESH_TOKEN " ${refresh_token_value_check_refresh_token} "
409409 { _check_access_token " ${account_name_check_refresh_token} " skip_check " ${response_check_refresh_token} " &&
You can’t perform that action at this time.
0 commit comments