• Resolved Bloke

    (@bloke)


    I am getting this Notice: get_post was called incorrectly. Product properties should not be accessed directly.

    This is the code I believe is the problem.

    function wc_add_short_description() {
    
    	global $product;
    	?>
    
    echo apply_filters( 'woocommerce_short_description', $product->post-> post_excerpt )
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Gabriel – a11n

    (@gabrielfuentes)

    Hi @bloke 👋

    Usually, this kind of problem is usually caused by either a conflict with your theme or with another plugin.

    The best way to check for conflicts is to:

    1. Temporarily switch your theme to Storefront theme
    2. Disable all plugins except for WooCommerce
    3. Check if the problem persist

    If you’re not seeing the same problem after completing the conflict test, then you know the problem was with the plugins and/or theme you deactivated.

    To figure out which plugin is causing the problem, reactivate your other plugins one by one, testing after each, until you find the one causing conflict. You can find a more detailed explanation on how to do a conflict test here.

    Before you start

    First, please make sure you have a good backup in place of your full site and database. If something goes wrong, it’s nice to know that you can restore your site.

    Second, I would suggest installing a plugin called Health Check & Troubleshooting. This is a plugin developed by the WordPress community and it allows you to disable plugins without affecting your current site visitors.

    Cheers!

    Plugin Support Gabriel – a11n

    (@gabrielfuentes)

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – we’ll be here if and/or when you are ready to continue.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘notice: get_post was called incorrectly’ is closed to new replies.