• Resolved maxsat67

    (@maxsat67)


    Hi, please help. But when I click on the Pay with PayPal button, I get the error “Something went wrong. Please try again or choose another payment source.”

    Errors in the Inspect Console:

    POST https://stluciataxis.com/?wc-ajax=ppc-create-order 500

    create_order_error 
    {err: 'SyntaxError: Unexpected token < in JSON at positio…nt=capture&enable-funding=venmo,paylater:2:143475', timestamp: '1632857713538', referer: 'www.paypal.com', sdkCorrelationID: 'f303757bc9270', sessionID: 'uid_7705429106_mtk6mji6mzy', …}
    buttonCorrelationID: "f20959078426a"
    buttonSessionID: "uid_e7c47ecab0_mtk6mzu6mdm"
    clientID: "ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx"
    env: "production"
    err: "SyntaxError: Unexpected token < in JSON at position 0\n\nError: Unexpected token < in JSON at position 0\n    at Nr.error (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:124394)\n    at Object.<anonymous> (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:132757)\n    at JSON.parse (<anonymous>)\n    at Dr.o (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:132616)\n    at Dr (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:132769)\n    at Kr.u.on (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:137437)\n    at Kr (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:137557)\n    at https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:143678\n    at Function.e.try (https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:71915)\n    at https://www.paypal.com/sdk/js?client-id=ASJ73UPn1mKOaZA8JMU1j7i8bWVgzjsn7S7tE37qFUNsMxoxACUCWK8AhrqagSNaMLfkZT2XoaWiBeTx&currency=USD&integration-date=2020-10-15&components=buttons,messages&vault=false&commit=true&intent=capture&enable-funding=venmo,paylater:2:143475"
    referer: "www.paypal.com"
    sdkCorrelationID: "f303757bc9270"
    sessionID: "uid_7705429106_mtk6mji6mzy"
    timestamp: "1632857713538"
    token: null
    user_id: "uid_e7c47ecab0_mtk6mzu6mdm"

    Logs:

    2021-09-28T19:35:13+00:00 CRITICAL Uncaught Error: Call to a member function get_name() on bool in /home1/caribbh8/public_html/stluciataxis/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-api-client/src/Factory/class-itemfactory.php:129
    Stack trace:
    #0 /home1/caribbh8/public_html/stluciataxis/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-api-client/src/Factory/class-itemfactory.php(89): WooCommerce\PayPalCommerce\ApiClient\Factory\ItemFactory->from_wc_order_line_item(Object(WC_Order_Item_Product), Object(Automattic\WooCommerce\Admin\Overrides\Order))
    #1 [internal function]: WooCommerce\PayPalCommerce\ApiClient\Factory\ItemFactory->WooCommerce\PayPalCommerce\ApiClient\Factory\{closure}(Object(WC_Order_Item_Product))
    #2 /home1/caribbh8/public_html/stluciataxis/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-api-client/src/Factory/class-itemfactory.php(91): array_map(Object(Closure), Array)
    #3 /home1/caribbh8/public_html/stluciataxis/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-api-client/src/F in /home1/caribbh8/public_html/stluciataxis/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-api-client/src/Factory/class-itemfactory.php on line 129
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Syde Joost

    (@joostvandevijver)

    Hello @maxsat67

    Thank you for reaching out to us. This issue we have not seen before.

    We have taken a look at this and see that for some reason the get_product is a boolean instead of a product. We suggest deactivating all other plugins and see if the issue persists or not. This could be a conflict with another plugin.

    Can you tell us the steps to reproduce this issue, so we can possibly try to do that in our testing environment?

    Kind regards,
    Joost

    Plugin Support Syde Joost

    (@joostvandevijver)

    Hello @maxsat67
    the issue with the error regarding “Call to a member function get_name() on bool” error should have been fixed in the release 1.6.2
    If this is still ongoing, please let us know. For now, we will mark this thread as resolved.

    Kind regards,
    Joost

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Checkout page: Something went wrong. Please try again or choose another payment’ is closed to new replies.