| @@ -63,15 +63,10 @@ | ||
| 63 | 63 | function ( tax, terms ) { |
| 64 | 64 | $.each( |
| 65 | 65 | terms, |
| 66 | 66 | function ( i ) { |
| 67 | - // Backward compatibility with WordPress < 6.7. | |
| 68 | - // Support both old (WP < 6.7) and new (WP >= 6.7) ID formats. | |
| 69 | - // Old format: category-123 (WordPress < 6.7). | |
| 70 | - // New format: in-category-123-1 (WordPress >= 6.7). | |
| 71 | 67 | const termId = pll_term_languages[ lg ][ tax ][ i ]; |
| 72 | - const selector = `#${tax}-${termId}, [id^="in-${tax}-${termId}-"]`; | |
| 73 | - $( selector ).toggle( lang === lg ); | |
| 68 | + $( `[id^="in-${tax}-${termId}-"]` ).toggle( lang === lg ); | |
| 74 | 69 | } |
| 75 | 70 | ); |
| 76 | 71 | } |
| 77 | 72 | ); |
| @@ -155,9 +150,9 @@ | ||
| 155 | 150 | if ( 'row' == this.what ) { |
| 156 | 151 | // data is built with a call to WP_Posts_List_Table::single_row method |
| 157 | 152 | // which uses internally other WordPress methods which escape correctly values. |
| 158 | 153 | // For Polylang language columns the HTML code is correctly escaped in PLL_Admin_Filters_Columns::post_column method. |
| 159 | - $( "#post-" + this.supplemental.post_id ).replaceWith( this.data ); // phpcs:ignore WordPressVIPMinimum.JS.HTMLExecutingFunctions.replaceWith | |
| 154 | + $( "#post-" + this.supplemental.post_id ).replaceWith( this.data ); | |
| 160 | 155 | } |
| 161 | 156 | } |
| 162 | 157 | ); |
| 163 | 158 | } |