Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Call to a member function get_id() on bool #1059

Closed
message-dimke opened this issue Aug 29, 2024 · 0 comments · Fixed by #1061
Closed

Call to a member function get_id() on bool #1059

message-dimke opened this issue Aug 29, 2024 · 0 comments · Fixed by #1061
Assignees
Labels
type: bug The issue is a confirmed bug.

Comments

@message-dimke
Copy link
Contributor

Describe the bug:

The plugin is causing a critical WordPress error.

wp-content/plugins/pinterest-for-woocommerce/src/Tracking.php:94 Call to a member function get_id() on bool.

All was working before the update (to the 1.4.7 version), so I am not sure if it is a product issue, but please let me know how we can fix it (the plugin has been deactivated for now to prevent the error from breaking the site).

Additional details:

My wild guess is that it is a product-related issue. The check for if is_product() passes, but then wc_get_product() returns bool value. And calling get_id() on bool obviously fails.

@message-dimke message-dimke added the type: bug The issue is a confirmed bug. label Aug 29, 2024
@message-dimke message-dimke self-assigned this Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug The issue is a confirmed bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant