Automattic / babble

Multilingual WordPress done right.
https://wordpress.org/plugins/babble/
245 stars 50 forks source link

Remove Bbl_Comment_Query #258

Open joehoyle opened 9 years ago

joehoyle commented 9 years ago

Bbl_Comment_Query was added as https://core.trac.wordpress.org/ticket/19623 had not yet been committed. Now this is in core, we should be able to remove Bbl_Comment_Query however I'm not sure of the minimum WordPress version supported which may affect this.

See https://github.com/Automattic/babble/blob/master/miscellaneous.php#L197

simonwheatley commented 9 years ago

however I'm not sure of the minimum WordPress version supported which may affect this.

I'd be happy to simply elevate the minimum WordPress version supported.

joehoyle commented 9 years ago

I took a deeper look into this - @simonwheatley if I could get a bit of background: it doesn't appear as if bbl_comments_template is auto hooked anywhere, so I'd guessing a theme author just has to use that instead.

However, I can't see anything specific to Babble about this template function. Is it just a comments_template with some general nice additions?

I doesn't appear that the custom args such as unapproved_author or unapproved_user_id have been added to WP_Comment_Query so we'd need to add filters to add support to WP_Comment_Query there.

simonwheatley commented 9 years ago

When a user comments on a translated post, that comment is made on the translation post and not on the post in the canonical language. Babble merges all the comment streams into one, so you can see all comments on any post in a translation group, regardless of language, in any post within that translation group. So for example, if you're reading the German post, you see the English and French comments as well as the German comments. On Free Speech Debate, we used Google Translate to allow machine translation of comments, to enable discussion across language barriers.

We had a lot of back and forth on whether this should be core Babble functionality, and, long story short, it ended up here.

More code here: https://github.com/Automattic/babble/blob/master/class-comment.php#L19-L38

Does that make things clearer, @joehoyle ?