summaryrefslogtreecommitdiff
path: root/Postman/PostmanUtils.php
diff options
context:
space:
mode:
authoryehudah <yehudah@b8457f37-d9ea-0310-8a92-e5e31aec5664>2019-08-24 22:08:56 +0000
committeryehudah <yehudah@b8457f37-d9ea-0310-8a92-e5e31aec5664>2019-08-24 22:08:56 +0000
commit59be4e796441e494f25b18ece7438dbf02442e47 (patch)
treedd893b6005411fa7621d3dd6a8ab0d5d664e75e4 /Postman/PostmanUtils.php
parent0c1f84b79c768e695fff224730b823517d3c5cc9 (diff)
downloadPost-SMTP-59be4e796441e494f25b18ece7438dbf02442e47.zip
security + multiple replyTo addreses
Diffstat (limited to 'Postman/PostmanUtils.php')
-rw-r--r--Postman/PostmanUtils.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/Postman/PostmanUtils.php b/Postman/PostmanUtils.php
index 335d0f3..6f628ec 100644
--- a/Postman/PostmanUtils.php
+++ b/Postman/PostmanUtils.php
@@ -345,6 +345,15 @@ class PostmanUtils {
if ( ! isset( PostmanUtils::$emailValidator ) ) {
PostmanUtils::$emailValidator = new Postman_Zend_Validate_EmailAddress();
}
+ if ( strpos( $email, ',' ) !== false ) {
+ $emails = explode(',', $email);
+ $result = [];
+ foreach ( $emails as $email ) {
+ $result[] = PostmanUtils::$emailValidator->isValid( $email );
+ }
+
+ return ! in_array(false, $result );
+ }
return PostmanUtils::$emailValidator->isValid( $email );
}