-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Better handling of broken Idna email addresses.
- Loading branch information
Showing
3 changed files
with
78 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
/** | ||
* | ||
*/ | ||
class Horde_ActiveSync_Mime_Headers_Addresses extends Horde_Mime_Headers_Addresses | ||
{ | ||
/** | ||
* Do send encoding for addresses. | ||
* | ||
* Needed as a static function because it is used by both single and | ||
* multiple address headers. | ||
* | ||
* @todo Implement with traits. | ||
* | ||
* @param array $alist An array of Horde_Mail_Rfc822_List objects. | ||
* @param array $opts Additional options: | ||
* - charset: (string) Encodes the headers using this charset. | ||
* DEFAULT: UTF-8 | ||
* - defserver: (string) The default domain to append to mailboxes. | ||
* DEFAULT: No default name. | ||
*/ | ||
public static function doSendEncode($alist, array $opts = array()) | ||
{ | ||
$opts['idn'] = false; | ||
return parent::doSendEncode($alist, $opts); | ||
} | ||
|
||
|
||
/** | ||
* @param array $opts See doSendEncode(). | ||
*/ | ||
protected function _sendEncode($opts) | ||
{ | ||
return self::doSendEncode($this->getAddressList(), $opts); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters