Daniel Koskinen
Member
Posted 2 years ago #
Hey!
Trying out your otherwise wonderful plugin with translated custom post types. Unfortunately it doesn't seem to work with them, instead showing all comments from all posts. Any ideas how to fix it? In this case I wouldn't mind hard coding the name of the post type if it comes to that.
http://wordpress.org/extend/plugins/wpml-comment-merging/
Daniel Koskinen
Member
Posted 2 years ago #
Actually I figured it out. You can support custom post types easily by changing lines 19 and 38 from this:
$type = is_page($post_ID) ? 'page' : 'post';
to this:
$type = get_post_type($post_ID);
After some brief testing with posts, pages and a custom post type I created, it seems to work just fine.