forked from LiveCarta/PayPal-PHP-SDK
Added missing apiContext arg
This commit is contained in:
@@ -251,7 +251,7 @@ class CreditCard extends Resource implements IResource {
|
|||||||
* @param string $creditcardid
|
* @param string $creditcardid
|
||||||
* @param PayPal\Rest\ApiContext $apiContext optional
|
* @param PayPal\Rest\ApiContext $apiContext optional
|
||||||
*/
|
*/
|
||||||
public static function get( $creditcardid) {
|
public static function get( $creditcardid, $apiContext=null) {
|
||||||
if (($creditcardid == null) || (strlen($creditcardid) <= 0)) {
|
if (($creditcardid == null) || (strlen($creditcardid) <= 0)) {
|
||||||
throw new \InvalidArgumentException("creditcardid cannot be null or empty");
|
throw new \InvalidArgumentException("creditcardid cannot be null or empty");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -179,7 +179,7 @@ class Payment extends Resource implements IResource {
|
|||||||
* All other keys in the map are ignored by the SDK
|
* All other keys in the map are ignored by the SDK
|
||||||
* @param PayPal\Rest\ApiContext $apiContext optional
|
* @param PayPal\Rest\ApiContext $apiContext optional
|
||||||
*/
|
*/
|
||||||
public static function all($params) {
|
public static function all($params, $apiContext=null) {
|
||||||
$payLoad = "";
|
$payLoad = "";
|
||||||
$allowedParams = array('count' => 1, 'start_id' => 1, 'start_index' => 1, 'start_time' => 1, 'end_time' => 1, 'payee_id' => 1, 'sort_by' => 1, 'sort_order' => 1, );
|
$allowedParams = array('count' => 1, 'start_id' => 1, 'start_index' => 1, 'start_time' => 1, 'end_time' => 1, 'payee_id' => 1, 'sort_by' => 1, 'sort_order' => 1, );
|
||||||
if($apiContext == null) {
|
if($apiContext == null) {
|
||||||
@@ -220,7 +220,7 @@ class Payment extends Resource implements IResource {
|
|||||||
* @param string $paymentid
|
* @param string $paymentid
|
||||||
* @param PayPal\Rest\ApiContext $apiContext optional
|
* @param PayPal\Rest\ApiContext $apiContext optional
|
||||||
*/
|
*/
|
||||||
public static function get( $paymentid) {
|
public static function get( $paymentid, $apiContext=null) {
|
||||||
if (($paymentid == null) || (strlen($paymentid) <= 0)) {
|
if (($paymentid == null) || (strlen($paymentid) <= 0)) {
|
||||||
throw new \InvalidArgumentException("paymentid cannot be null or empty");
|
throw new \InvalidArgumentException("paymentid cannot be null or empty");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -184,7 +184,7 @@ class Refund extends Resource implements IResource {
|
|||||||
* @param string $refundid
|
* @param string $refundid
|
||||||
* @param PayPal\Rest\ApiContext $apiContext optional
|
* @param PayPal\Rest\ApiContext $apiContext optional
|
||||||
*/
|
*/
|
||||||
public static function get( $refundid) {
|
public static function get( $refundid, $apiContext=null) {
|
||||||
if (($refundid == null) || (strlen($refundid) <= 0)) {
|
if (($refundid == null) || (strlen($refundid) <= 0)) {
|
||||||
throw new \InvalidArgumentException("refundid cannot be null or empty");
|
throw new \InvalidArgumentException("refundid cannot be null or empty");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -136,7 +136,7 @@ class Sale extends Resource implements IResource {
|
|||||||
* @param string $saleid
|
* @param string $saleid
|
||||||
* @param PayPal\Rest\ApiContext $apiContext optional
|
* @param PayPal\Rest\ApiContext $apiContext optional
|
||||||
*/
|
*/
|
||||||
public static function get( $saleid) {
|
public static function get( $saleid, $apiContext=null) {
|
||||||
if (($saleid == null) || (strlen($saleid) <= 0)) {
|
if (($saleid == null) || (strlen($saleid) <= 0)) {
|
||||||
throw new \InvalidArgumentException("saleid cannot be null or empty");
|
throw new \InvalidArgumentException("saleid cannot be null or empty");
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user