Integrating with Pro Sites IPN handler

Hi,

I am currently integrating a 3rd party affiliate system with Pro Sites and need a little direction regarding the following:

In order for the affiliate system to account for sales, the following code needs to be added to the portion of the file that is called by the PayPal IPN url on payment completion. It seems the correct file is /wp-content/plugins/pro-sites/pro-sites-files/gateways/gateway-paypal-express-pro.php , but within which part of the file should the code be placed (ie. under "process PayPal response", "case 'Completed':", etc)?

the code to be added is:

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://affiliate.mydomain.com/plugins/PayPal/paypal.php");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $_POST);
curl_exec($ch);

The configuration docs for the affiliate system say that when the PayPal IPN response is made (from paypal to the pro-site IPN url) the affiliate system needs to be alerted (at https://affiliate.mydomain.com/plugins/PayPal/paypal.php), which is the purpose of the above code.

I believe I have everything worked out except for which portion of the "gateway-paypal-express-pro.php" should contain that code.

Thank you in advance!