Ticket #6592: 6592.decode.patch
File 6592.decode.patch, 1.7 KB (added by , 4 years ago) |
---|
-
src/bp-core/bp-core-filters.php
349 349 add_filter( 'bp_login_redirect', 'bp_core_login_redirect', 10, 3 ); 350 350 351 351 /** 352 * Decode HTML entities for plain-text emails. 353 * 354 * @since 2.5.0 355 * 356 * @param string $retval Current email content. 357 * @param string $prop Email property to check against. 358 */ 359 function bp_email_plaintext_entity_decode( $retval, $prop ) { 360 if ( 'content_plaintext' !== $prop ) { 361 return $retval; 362 } 363 364 return html_entity_decode( $retval, ENT_QUOTES ); 365 } 366 add_filter( 'bp_email_get_property', 'bp_email_plaintext_entity_decode', 10, 2 ); 367 368 /** 352 369 * Replace the generated password in the welcome email with '[User Set]'. 353 370 * 354 371 * On a standard BP installation, users who register themselves also set their -
src/bp-messages/bp-messages-notifications.php
60 60 61 61 $args = array( 62 62 'tokens' => array( 63 'usermessage' => wp_strip_all_tags( $message),64 'message.url' => esc_url( bp_core_get_user_domain( $recipient->user_id ) . bp_get_messages_slug() . '/ ' ),63 'usermessage' => wp_strip_all_tags( stripslashes( $message ) ), 64 'message.url' => esc_url( bp_core_get_user_domain( $recipient->user_id ) . bp_get_messages_slug() . '/view/' . $thread_id . '/' ), 65 65 'sender.name' => $sender_name, 66 'usersubject' => sanitize_text_field( $subject),66 'usersubject' => sanitize_text_field( stripslashes( $subject ) ), 67 67 ), 68 68 ); 69 69 bp_send_email( 'messages-unread', $ud, $args );