From 6087461192fe1b396d520e9c5bc0eda9b711de05 Mon Sep 17 00:00:00 2001 From: hakito Date: Sun, 6 Oct 2013 20:38:58 +0200 Subject: [PATCH 1/3] Show response instead of request in ExecutePayment --- sample/payments/ExecutePayment.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sample/payments/ExecutePayment.php b/sample/payments/ExecutePayment.php index ca87360..600d418 100644 --- a/sample/payments/ExecutePayment.php +++ b/sample/payments/ExecutePayment.php @@ -29,10 +29,10 @@ if(isset($_GET['success']) && $_GET['success'] == 'true') { //Execute the payment // (See bootstrap.php for more on `ApiContext`) - $payment->execute($execution, $apiContext); + $response = $payment->execute($execution, $apiContext); echo "
";
-	var_dump($payment->toArray());
+	var_dump($response->toArray());
 	echo "
Back"; } else { From c1298112fabb4ca29aa0b9d31e8b8576e9c9bf22 Mon Sep 17 00:00:00 2001 From: hakito Date: Sun, 6 Oct 2013 20:49:49 +0200 Subject: [PATCH 2/3] Fix path in bootstrap for samples when installed via composer When installing the SDK as recommended via composer, the samples don't work because it can not find the autloader of composer --- sample/bootstrap.php | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/sample/bootstrap.php b/sample/bootstrap.php index 4d37165..2b28aa0 100644 --- a/sample/bootstrap.php +++ b/sample/bootstrap.php @@ -1,17 +1,20 @@ Date: Thu, 10 Oct 2013 20:34:28 +0200 Subject: [PATCH 3/3] Minor fix of previous commit --- sample/bootstrap.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sample/bootstrap.php b/sample/bootstrap.php index 2b28aa0..48ead06 100644 --- a/sample/bootstrap.php +++ b/sample/bootstrap.php @@ -5,7 +5,7 @@ // Include the composer autoloader $composerAutoload = dirname(dirname(dirname(__DIR__))) . '/autoload.php'; -if (file_exists($composerAutoload)) +if (!file_exists($composerAutoload)) { $composerAutoload = __DIR__ .'/vendor/autoload.php';