From f83fc0c77e3e1bbb656b96a590d8ec3caa67b01a Mon Sep 17 00:00:00 2001 From: Philipp Batroff Date: Thu, 18 Jul 2019 11:34:18 +0200 Subject: [PATCH] udpate parsing of response codes from civicrm api --- proxy/webhook2api.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/proxy/webhook2api.php b/proxy/webhook2api.php index 93fa90f..da9a38f 100644 --- a/proxy/webhook2api.php +++ b/proxy/webhook2api.php @@ -112,8 +112,8 @@ function webhook2api_processConfiguration($configuration, $post_input) { // internal communication Error occured. Aborting process return $result['internal_error']; } - if (!empty($result['http_code'])) { - $http_code = $result['http_code']; + if (!empty($result['values']['http_code'])) { + $http_code = $result['values']['http_code']; } else { $http_code = 403; break; @@ -125,8 +125,8 @@ function webhook2api_processConfiguration($configuration, $post_input) { // internal communication Error occured. Aborting process return $result['internal_error']; } - if (!empty($result['http_code'])) { - $http_code = $result['http_code']; + if (!empty($result['values']['http_code'])) { + $http_code = $result['values']['http_code']; } else { $http_code = 403; }