• Resolved user9876789

    (@user9876789)


    Hello, I have an error in the log which occurs when someone does a search. The criteria it happens under is multiple post types need to be ticked in the Edit Widget area > Items to Search Through (either Products and Posts, or Products and pages). Issue doesn’t happen if posts and pages only are ticked.

    When a search is done the URL is e.g. ?s=roses&search_id=1&post_type=product

    Then I get this error in the log:

    Got error ‘PHP message: PHP Warning:? Attempt to read property “labels” on null in /var/www/vhosts/******/httpdocs/wp-includes/general-template.php on line 3232PHP message: PHP Warning:? Attempt to read property “name” on null in /var/www/vhosts/****/httpdocs/wp-includes/general-template.php on line 3232PHP message: PHP Warning:? Attempt to read property “name” on null in /var/www/vhosts/****/httpdocs/wp-includes/general-template.php on line 3235’, referer: https://***/?s=climbing&search_id=1&post_type=product

    Diving into /wp-includes/general-template.php line 3232 and var_dumping $post_type returns a string of “post,product”, then var_dumping $post_type_obj returns null.

    If I only tick product, $post_type returns “product” and $post_type_obj does not return null, it returns the product CPT.

    Please could you take a look at this?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author YummyWP

    (@yummy-wp)

    Hi there,

    I can’t reproduce the issue on the testing server.

    Can you please create a support ticket here and attach a screenshots with settings of Smart Search widget #1?

    Thread Starter user9876789

    (@user9876789)

    I couldnt attach screenshots but I’ve submitted a ticket – if you can reply to me via email I can reply with screenshots

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Error in Log’ is closed to new replies.