WordPress.org

Ready to get started?Download WordPress

Forums

WP eCommerce
[resolved] Catchable fatal error: Object of class WP_Error could not be converted to string (2 posts)

  1. LimeCanvas
    Member
    Posted 1 year ago #

    Full issue is described here.
    http://getshopped.org/forums/topic/catchable-fatal-error-object-of-class-wp_error-could-not-be-converted-to-string/#post-297087

    Essentially there is a problem in /plugins/wp-e-commerce/wpsc-merchants/paypal-express.merchant.php on line 586

    The sessionid variable is being cast to a string but the function wpsc_get_customer_meta() on line 1697 /wp-ecommerce/wpsc-core/wpsc-functions.php returns a WP_Error on error.

    WP_Error is an object and can’t be cast to a string.

    Here's a fix.

    Replace line 586 in paypal-express.merchant.php with the following three lines:

    $sessionid = wpsc_get_customer_meta( 'paypal_express_sessionid' );
    if( is_wp_error( $sessionid ) )
    return $sessonid->get_error_message();

    Would be nice to see this in the next WPEC core update.

    Cheerz,
    Wil.

    http://wordpress.org/extend/plugins/wp-e-commerce/

  2. Visser Labs
    Member
    Plugin Author

    Posted 1 year ago #

    Hi Wil, thanks for raising this. I'e passed it onto the GetShopped.org team for inclusion in a future Plugin update. :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.