Skip to content

Commit

Permalink
Use single string literal for i18n function
Browse files Browse the repository at this point in the history
  • Loading branch information
hanifn committed Jun 14, 2024
1 parent d757db0 commit 0d6ddf2
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions modules/notifications/notifications.php
Original file line number Diff line number Diff line change
Expand Up @@ -815,9 +815,10 @@ public function notification_comment( $comment ) {
$this->send_email( 'comment', $post, $subject, $body );

if ( 'on' === $this->module->options->send_to_webhook ) {
/* translators: 1: comment author, 2: post type, 3: post id, 4: edit link, 5: post title */
$format = __( '*%1$s* left a comment on *%2$s #%3$s - <%4$s|%5$s>*' . "\n\n" . '%6$s', 'edit-flow' );
$text = sprintf( $format, $comment->comment_author, $post_type, $post_id, $edit_link, $post_title, $comment->comment_content );
/* translators: 1: comment author, 2: post type, 3: post id, 4: edit link, 5: post title, 6: comment content */
$format = __( '*%1$s* left a comment on *%2$s #%3$s - <%4$s|%5$s>*', 'edit-flow' ) . "\n\n";
$format .= '%6$s';
$text = sprintf( $format, $comment->comment_author, $post_type, $post_id, $edit_link, $post_title, $comment->comment_content );

$this->send_to_webhook( $text );
}
Expand Down

0 comments on commit 0d6ddf2

Please sign in to comment.