diff --git src/wp-trackback.php src/wp-trackback.php
index 6bc8495a9f..4c772971f0 100644
|
|
if ( ! empty( $tb_url ) && ! empty( $title ) ) { |
118 | 118 | $title = wp_html_excerpt( $title, 250, '…' ); |
119 | 119 | $excerpt = wp_html_excerpt( $excerpt, 252, '…' ); |
120 | 120 | |
121 | | $comment_post_ID = (int) $tb_id; |
| 121 | $comment_post_ID = (int) $tb_id; // phpcs:ignore WordPress.NamingConventions.ValidVariableName.NotSnakeCase |
122 | 122 | $comment_author = $blog_name; |
123 | 123 | $comment_author_email = ''; |
124 | 124 | $comment_author_url = $tb_url; |
125 | 125 | $comment_content = "<strong>$title</strong>\n\n$excerpt"; |
126 | 126 | $comment_type = 'trackback'; |
127 | 127 | |
| 128 | // phpcs:ignore WordPress.NamingConventions.ValidVariableName.NotSnakeCase |
128 | 129 | $dupe = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM $wpdb->comments WHERE comment_post_ID = %d AND comment_author_url = %s", $comment_post_ID, $comment_author_url ) ); |
129 | 130 | if ( $dupe ) { |
130 | 131 | trackback_response( 1, __( 'We already have a ping from that URL for this post.' ) ); |