PluginProbe
Polylang / 2.6.3
Polylang v2.6.3
3.8.9 3.8.8 3.8.7 3.8.6 3.8.5 3.8.4 3.8.3 2.7 2.7.0.1 2.7.1 2.7.2 2.7.3 2.7.4 2.8 2.8.1 2.8.2 2.8.3 2.8.4 2.9 2.9.1 2.9.2 3.0 3.0.1 3.0.2 3.0.3 All 233 releases
← All changes | modules/sync/sync-tax.php +1 -6 2.7.42.6.3 View file →
@@ -162,14 +162,9 @@
162 162 $this->copy_object_terms( $object_id, $tr_id, $lang, $terms, $taxonomy, $append );
163 163 } else {
164 164 // No permission to synchronize, so let's synchronize in reverse order
165 165 $orig_lang = array_search( $object_id, $tr_ids );
166 - $tr_terms = get_the_terms( $tr_id, $taxonomy );
167 -
168 - if ( false === $tr_terms ) {
169 - $tr_terms = array();
170 - }
171 -
166 + $tr_terms = (array) get_the_terms( $tr_id, $taxonomy );
172 167 if ( is_array( $tr_terms ) ) {
173 168 $tr_terms = wp_list_pluck( $tr_terms, 'term_id' );
174 169 $this->copy_object_terms( $tr_id, $object_id, $orig_lang, $tr_terms, $taxonomy, $append );
175 170 }