mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #4759 from edlinklater/3.2-mailer-validemailaddr
Handle incorrectly deprecated validEmailAddr methods
This commit is contained in:
commit
8368ead424
@ -451,6 +451,14 @@ class Mailer extends Object {
|
||||
return $headers . $file['contents'];
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated since version 4.0
|
||||
*/
|
||||
public function validEmailAddr($emailAddress) {
|
||||
Deprecation::notice('4.0', 'This method will be removed in 4.0. Use protected method Mailer->validEmailAddress().');
|
||||
return $this->validEmailAddress($emailAddress);
|
||||
}
|
||||
|
||||
/**
|
||||
* Cleans up emails which may be in 'Name <email@silverstripe.com>' format
|
||||
*
|
||||
@ -596,8 +604,8 @@ function QuotedPrintable_encode($quotprint) {
|
||||
* @deprecated 3.1
|
||||
*/
|
||||
function validEmailAddr($emailAddress) {
|
||||
Deprecation::notice('4.0', 'Use Email->validEmailAddr() instead');
|
||||
Deprecation::notice('4.0', 'This method will be removed in 4.0. Use protected method Mailer->validEmailAddress().');
|
||||
|
||||
$mailer = Injector::inst()->create('Mailer');
|
||||
return $mailer->validEmailAddr($emailAddress);
|
||||
return $mailer->validEmailAddr($emailAddress);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user