diff --git a/lib/ObjectSerializer.php b/lib/ObjectSerializer.php index 160619f..48841d0 100644 --- a/lib/ObjectSerializer.php +++ b/lib/ObjectSerializer.php @@ -494,8 +494,9 @@ public static function deserialize($data, $class, $httpHeaders = null) if (method_exists($class, 'getAllowableEnumValues')) { - if (!in_array($data, $class::getAllowableEnumValues(), true)) { - $data = end($class::getAllowableEnumValues()); + $enumValues = $class::getAllowableEnumValues(); + if (!in_array($data, $enumValues, true)) { + $data = end($enumValues); } return $data; } else { diff --git a/lib/PaymentMethod/DirectDebitChannelCode.php b/lib/PaymentMethod/DirectDebitChannelCode.php index df17fa2..ea3ef2d 100644 --- a/lib/PaymentMethod/DirectDebitChannelCode.php +++ b/lib/PaymentMethod/DirectDebitChannelCode.php @@ -223,6 +223,12 @@ class DirectDebitChannelCode public const XENDIT_ENUM_DEFAULT_FALLBACK = 'UNKNOWN_ENUM_VALUE'; + public const BPI_DIRECT_DEBIT = 'BPI_DIRECT_DEBIT'; + + public const UBP_DIRECT_DEBIT = 'UBP_DIRECT_DEBIT'; + + public const RCBC_DIRECT_DEBIT = 'RCBC_DIRECT_DEBIT'; + private $value; public function __construct($value = null) { @@ -343,7 +349,10 @@ public static function getAllowableEnumValues() self::GBW_KTB, self::GBW_SCB, self::GBW_BAY, - self::XENDIT_ENUM_DEFAULT_FALLBACK + self::XENDIT_ENUM_DEFAULT_FALLBACK, + self::BPI_DIRECT_DEBIT, + self::UBP_DIRECT_DEBIT, + self::RCBC_DIRECT_DEBIT ]; } } diff --git a/lib/PaymentRequest/DirectDebitChannelCode.php b/lib/PaymentRequest/DirectDebitChannelCode.php index 17d5ead..2cc35b6 100644 --- a/lib/PaymentRequest/DirectDebitChannelCode.php +++ b/lib/PaymentRequest/DirectDebitChannelCode.php @@ -199,6 +199,12 @@ class DirectDebitChannelCode public const XENDIT_ENUM_DEFAULT_FALLBACK = 'UNKNOWN_ENUM_VALUE'; + public const BPI_DIRECT_DEBIT = 'BPI_DIRECT_DEBIT'; + + public const UBP_DIRECT_DEBIT = 'UBP_DIRECT_DEBIT'; + + public const RCBC_DIRECT_DEBIT = 'RCBC_DIRECT_DEBIT'; + private $value; public function __construct($value = null) { @@ -307,7 +313,10 @@ public static function getAllowableEnumValues() self::RCBC_ONLINE_BANKING, self::ROBINSONS_BANK_ONLINE_BANKING, self::SECURITY_BANK_ONLINE_BANKING, - self::XENDIT_ENUM_DEFAULT_FALLBACK + self::XENDIT_ENUM_DEFAULT_FALLBACK, + self::BPI_DIRECT_DEBIT, + self::UBP_DIRECT_DEBIT, + self::RCBC_DIRECT_DEBIT ]; } } diff --git a/lib/PaymentRequest/EWalletChannelCode.php b/lib/PaymentRequest/EWalletChannelCode.php index 55ffd1c..122f8b0 100644 --- a/lib/PaymentRequest/EWalletChannelCode.php +++ b/lib/PaymentRequest/EWalletChannelCode.php @@ -76,6 +76,8 @@ class EWalletChannelCode public const ALIPAY = 'ALIPAY'; public const TOUCHNGO = 'TOUCHNGO'; + + public const GOPAY = 'GOPAY'; public const XENDIT_ENUM_DEFAULT_FALLBACK = 'UNKNOWN_ENUM_VALUE'; @@ -127,6 +129,7 @@ public static function getAllowableEnumValues() self::TRUEMONEY, self::ALIPAY, self::TOUCHNGO, + self::GOPAY, self::XENDIT_ENUM_DEFAULT_FALLBACK ]; }