X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FCore%2FPayment.php;h=502d332df305b91535b98bb04b91b191ca6d991f;hb=7646662a2002fac1f942d0a590145c38e735891f;hp=eaa4cce0ee3804a27ee118d1d1ba518b9320ccfd;hpb=de6290187b3d3332be345c76944d66da658ac210;p=civicrm-core.git diff --git a/CRM/Core/Payment.php b/CRM/Core/Payment.php index eaa4cce0ee..502d332df3 100644 --- a/CRM/Core/Payment.php +++ b/CRM/Core/Payment.php @@ -261,7 +261,14 @@ abstract class CRM_Core_Payment { } $log = new CRM_Utils_SystemLogger(); - $log->alert($message, $_REQUEST); + // $_REQUEST doesn't handle JSON, to support providers that POST JSON we need the raw POST data. + $rawRequestData = file_get_contents("php://input"); + if (CRM_Utils_JSON::isValidJSON($rawRequestData)) { + $log->alert($message, json_decode($rawRequestData, TRUE)); + } + else { + $log->alert($message, $_REQUEST); + } } /**