PluginProbe
Polylang / 2.8
Polylang v2.8
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-classic-editor.php +13 -2 2.7.32.8 View file →
@@ -1,5 +1,8 @@
1 1 <?php
2 +/**
3 + * @package Polylang
4 + */
2 5
3 6 /**
4 7 * Manages filters and actions related to the classic editor
5 8 *
@@ -111,9 +114,13 @@
111 114 do_action( 'pll_before_post_translations', $post_type );
112 115
113 116 echo '<div id="post-translations" class="translations">';
114 117 if ( $lang ) {
115 - include PLL_ADMIN_INC . '/view-translations-' . ( 'attachment' == $post_type ? 'media' : 'post' ) . '.php';
118 + if ( 'attachment' === $post_type ) {
119 + include __DIR__ . '/view-translations-media.php';
120 + } else {
121 + include __DIR__ . '/view-translations-post.php';
122 + }
116 123 }
117 124 echo '</div>' . "\n";
118 125 }
119 126
@@ -151,9 +158,13 @@
151 158 $this->model->post->save_translations( $post_ID, $translations );
152 159
153 160 ob_start();
154 161 if ( $lang ) {
155 - include PLL_ADMIN_INC . '/view-translations-' . ( 'attachment' == $post_type ? 'media' : 'post' ) . '.php';
162 + if ( 'attachment' === $post_type ) {
163 + include __DIR__ . '/view-translations-media.php';
164 + } else {
165 + include __DIR__ . '/view-translations-post.php';
166 + }
156 167 }
157 168 $x = new WP_Ajax_Response( array( 'what' => 'translations', 'data' => ob_get_contents() ) );
158 169 ob_end_clean();
159 170