File tree Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Original file line number Diff line number Diff line change 55if (!function_exists ('is_email ' )) {
66 /**
77 * Check whether the given string is an email address or not.
8- *
9- * @param mixed $string
10- * @return bool
118 */
12- function is_email ($ string )
9+ function is_email (mixed $ string ): bool
1310 {
1411 return (bool ) filter_var ($ string , FILTER_VALIDATE_EMAIL );
1512 }
@@ -21,11 +18,8 @@ function is_email($string)
2118 *
2219 * @see http://faqs.org/rfcs/rfc2822.html
2320 * @see https://php.net/manual/en/function.mail.php
24- *
25- * @param array $addresses
26- * @return string
2721 */
28- function to_rfc2822_email (array $ addresses )
22+ function to_rfc2822_email (array $ addresses ): string
2923 {
3024 // Check if we're dealing with one address, without multiarray
3125 $ addresses = !empty ($ addresses ['address ' ]) ? [$ addresses ] : $ addresses ;
@@ -51,11 +45,8 @@ function to_rfc2822_email(array $addresses)
5145 * Convert addresses data to SwiftMailer-suitable format.
5246 *
5347 * @see https://swiftmailer.org/docs/messages.html
54- *
55- * @param array $addresses
56- * @return array
5748 */
58- function to_swiftmailer_emails (array $ addresses )
49+ function to_swiftmailer_emails (array $ addresses ): array
5950 {
6051 // Check if we're dealing with one address, without multiarray
6152 $ addresses = !empty ($ addresses ['address ' ]) ? [$ addresses ] : $ addresses ;
You can’t perform that action at this time.
0 commit comments