@@ 1454-1461 (lines=8) @@ | ||
1451 | ||
1452 | $slug_count = count( $existing_term_slugs ); |
|
1453 | ||
1454 | if ( $slug_count > 1 ) { |
|
1455 | $remove_url = Jetpack_Search_Helpers::add_query_arg( |
|
1456 | $tax_query_var, |
|
1457 | rawurlencode( implode( '+', array_diff( $existing_term_slugs, array( $item['key'] ) ) ) ) |
|
1458 | ); |
|
1459 | } else { |
|
1460 | $remove_url = Jetpack_Search_Helpers::remove_query_arg( $tax_query_var ); |
|
1461 | } |
|
1462 | } |
|
1463 | ||
1464 | break; |
|
@@ 1492-1499 (lines=8) @@ | ||
1489 | $post_type_count = count( $post_types ); |
|
1490 | ||
1491 | // For the right 'remove filter' url, we need to remove the post type from the array, or remove the param entirely if it's the only one |
|
1492 | if ( $post_type_count > 1 ) { |
|
1493 | $remove_url = Jetpack_Search_Helpers::add_query_arg( |
|
1494 | 'post_type', |
|
1495 | rawurlencode( implode( ',', array_diff( $post_types, array( $item['key'] ) ) ) ) |
|
1496 | ); |
|
1497 | } else { |
|
1498 | $remove_url = Jetpack_Search_Helpers::remove_query_arg( 'post_type' ); |
|
1499 | } |
|
1500 | } |
|
1501 | ||
1502 | break; |