PluginProbe
Polylang / 2.5.2
Polylang v2.5.2
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 | admin/admin-filters-post-base.php +0 -2 2.72.5.2 View file →
@@ -33,10 +33,8 @@
33 33 protected function save_translations( $post_id, $arr ) {
34 34 // Security check as 'wp_insert_post' can be called from outside WP admin
35 35 check_admin_referer( 'pll_language', '_pll_nonce' );
36 36
37 - $translations = array();
38 -
39 37 // Save translations after checking the translated post is in the right language
40 38 foreach ( $arr as $lang => $tr_id ) {
41 39 $translations[ $lang ] = ( $tr_id && $this->model->post->get_language( (int) $tr_id )->slug == $lang ) ? (int) $tr_id : 0;
42 40 }