|
|
|
@ -151,7 +151,10 @@ function fulcrm_webhook_webhook( $uuid ) {
|
|
|
|
|
if ( array_key_exists( 'Content-Type', $headers ) && ( $headers[ 'Content-Type' ] === 'application/json' ) ) {
|
|
|
|
|
$payload = json_decode( file_get_contents( "php://input" ), $assoc = TRUE );
|
|
|
|
|
$payload_error = json_last_error();
|
|
|
|
|
$payload_error_msg = json_last_error_msg();
|
|
|
|
|
if ( function_exists( 'json_last_error_msg' ) )
|
|
|
|
|
$payload_error_msg = json_last_error_msg();
|
|
|
|
|
else
|
|
|
|
|
$payload_error_msg = 'JSON error unavailable';
|
|
|
|
|
} else {
|
|
|
|
|
$payload_error_msg = 'no payload';
|
|
|
|
|
}
|
|
|
|
|