mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 07:28:39 +01:00
ddns-scripts: cloudflare.com-v4: Fix success check for new response format
JSON response now has spaces between parameters. Accept this new format and the old one.
Signed-off-by: Michael Gray <michael.gray@lantisproject.com>
(cherry picked from commit 0080bb4bba)
This commit is contained in:
@@ -85,7 +85,7 @@ cloudflare_transfer() {
|
|||||||
done
|
done
|
||||||
|
|
||||||
# check for error
|
# check for error
|
||||||
grep -q '"success":true' $DATFILE || {
|
grep -q '"success": \?true' $DATFILE || {
|
||||||
write_log 4 "CloudFlare reported an error:"
|
write_log 4 "CloudFlare reported an error:"
|
||||||
write_log 7 "$(cat $DATFILE)" # report error
|
write_log 7 "$(cat $DATFILE)" # report error
|
||||||
return 1 # HTTP-Fehler
|
return 1 # HTTP-Fehler
|
||||||
|
|||||||
Reference in New Issue
Block a user