Ticket #28407: 28407.diff
File 28407.diff, 912 bytes (added by , 11 years ago) |
---|
-
wp-includes/pluggable.php
500 500 $phpmailer->AddCustomHeader( sprintf( "Content-Type: %s;\n\t boundary=\"%s\"", $content_type, $boundary ) ); 501 501 } 502 502 503 if ( !empty( $attachments ) ) { 504 foreach ( $attachments as $attachment ) { 503 if ( !empty( $attachments ) && is_array( $attachments ) ) { 504 // check if $attachments is associative array or not 505 $is_assoc_array = array_keys( $attachments ) !== range( 0, count( $attachments ) - 1 ); 506 foreach ( $attachments as $name => $attachment ) { 505 507 try { 506 $phpmailer->AddAttachment($attachment);508 ( $is_assoc_array ) ? $phpmailer->AddAttachment( $attachment, $name ) : $phpmailer->AddAttachment( $attachment ); 507 509 } catch ( phpmailerException $e ) { 508 510 continue; 509 511 }