clerkio / clerk-woocommerce

WooCommerce extension for Clerk.io
MIT License
4 stars 19 forks source link

Critical uncaught error in some cases #101

Open Dekadinious opened 3 months ago

Dekadinious commented 3 months ago
Uncaught Error: Cannot use object of type WP_Error as array in /www/any/wp-content/plugins/clerkio/includes/class-clerk-rest-api.php:1572  
Context:
{
    "error": {
        "type": 1,
        "file": "\/www\/any\/wp-content\/plugins\/clerkio\/includes\/class-clerk-rest-api.php",
        "line": 1572
    },
    "backtrace": [
        "",
        "#0 \/www\/any\/wp-content\/plugins\/clerkio\/includes\/class-clerk-rest-api.php(1526): Clerk_Rest_Api->validate_jwt()",
        "#1 \/www\/any\/wp-content\/plugins\/clerkio\/includes\/class-clerk-rest-api.php(285): Clerk_Rest_Api->validate_request()",
        "#2 \/www\/any\/wp-includes\/rest-api\/class-wp-rest-server.php(1230): Clerk_Rest_Api->product_endpoint_callback()",
        "#3 \/www\/any\/wp-includes\/rest-api\/class-wp-rest-server.php(1063): WP_REST_Server->respond_to_request()",
        "#4 \/www\/any\/wp-includes\/rest-api\/class-wp-rest-server.php(439): WP_REST_Server->dispatch()",
        "#5 \/www\/any\/wp-includes\/rest-api.php(428): WP_REST_Server->serve_request()",
        "#6 \/www\/any\/wp-includes\/class-wp-hook.php(324): rest_api_loaded()",
        "#7 \/www\/any\/wp-includes\/class-wp-hook.php(348): WP_Hook->apply_filters()",
        "#8 \/www\/any\/wp-includes\/plugin.php(565): WP_Hook->do_action()",
        "#9 \/www\/any\/wp-includes\/class-wp.php(418): do_action_ref_array()",
        "#10 \/www\/any\/wp-includes\/class-wp.php(813): WP->parse_request()",
        "#11 \/www\/any\/wp-includes\/functions.php(1336): WP->main()",
        "#12 \/www\/any\/wp-blog-header.php(16): wp()",
        "#13 \/www\/any\/index.php(17): require('\/www\/any\/wp-blo...')",
        "#14 {main}",
        "thrown"
    ]
}
Dekadinious commented 4 days ago

Also happens in Uncaught Error: Cannot use object of type WP_Error as array in /www/any/wp-content/plugins/clerkio/includes/class-clerk-rest-api.php:1616