• Resolved ntolib

    (@ntolib)


    Dear Dev Team,

    First of all thanks for your great job. You made perfect product.

    I want to use the standard WP comments as a reviews for the posts (post, custom post types) and query it all on the separate page (Reviews).
    So, if I restrict the access to the required post then the comments posted on this post are not visible on the Reviews page.

    Is any idea to exclude the comments from the restriction?
    I didn’t find any hooks/samples in Documentation and here in forum.

    It will be great if you’ll add this option in the plugin settings like you made for the “Replace the restricted Post Title”.

    Thanks a in advance.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support andrewshu

    (@andrewshu)

    Hello @ntolib

    Try to add this code to your functions.php file in your child theme folder:

    remove_action( 'pre_get_comments', array( UM()->access(), 'exclude_posts_comments' ), 99, 1 );

    Thank you.

    Thread Starter ntolib

    (@ntolib)

    Perfect!
    Works well.
    Thank you!

    • This reply was modified 3 years, 2 months ago by ntolib.
Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Exclude comments from restrictions’ is closed to new replies.