Fix for WPML

leave $post_ids as a unique array for the query