mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 14:57:26 +08:00
Rename plugin to "WooCommerce PayPal Payments"
This commit is contained in:
parent
a8c36bc260
commit
02718c6c77
60 changed files with 497 additions and 497 deletions
|
@ -120,17 +120,17 @@ class ItemFactory {
|
|||
public function from_paypal_response( \stdClass $data ): Item {
|
||||
if ( ! isset( $data->name ) ) {
|
||||
throw new RuntimeException(
|
||||
__( 'No name for item given', 'paypal-payments-for-woocommerce' )
|
||||
__( 'No name for item given', 'woocommerce-paypal-payments' )
|
||||
);
|
||||
}
|
||||
if ( ! isset( $data->quantity ) || ! is_numeric( $data->quantity ) ) {
|
||||
throw new RuntimeException(
|
||||
__( 'No quantity for item given', 'paypal-payments-for-woocommerce' )
|
||||
__( 'No quantity for item given', 'woocommerce-paypal-payments' )
|
||||
);
|
||||
}
|
||||
if ( ! isset( $data->unit_amount->value ) || ! isset( $data->unit_amount->currency_code ) ) {
|
||||
throw new RuntimeException(
|
||||
__( 'No money values for item given', 'paypal-payments-for-woocommerce' )
|
||||
__( 'No money values for item given', 'woocommerce-paypal-payments' )
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue