Automattic / babble

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

Fix the lang_map properties in Babble_Post_Public #283

Closed johnbillion closed 9 years ago

johnbillion commented 9 years ago

See #240

I'd been considering refactoring these properties into one, but there's actually a valid requirement for them both to exist. lang_map is a lookup table for fetching the language of a shadow post type. lang_map2 is a lookup for fetching the shadow post type given a language and a source post type.

To that end, I've renamed the lang_map and lang_map2 properties in Babble_Post_Public to post_type_map and lang_map respectively, so they're at parity with the lang_map property in Babble_Taxonomies, and I've improved the inline documentation.

There's no functional change and the tests remain passing.