Aggiornato Composer
This commit is contained in:
@@ -109,6 +109,11 @@ abstract class AbstractHeader implements HeaderInterface
|
||||
}
|
||||
$phraseStr = $this->encodeWords($header, $string, $usedLength);
|
||||
}
|
||||
} elseif (str_contains($phraseStr, '(')) {
|
||||
foreach (['\\', '"'] as $char) {
|
||||
$phraseStr = str_replace($char, '\\'.$char, $phraseStr);
|
||||
}
|
||||
$phraseStr = '"'.$phraseStr.'"';
|
||||
}
|
||||
|
||||
return $phraseStr;
|
||||
@@ -195,7 +200,7 @@ abstract class AbstractHeader implements HeaderInterface
|
||||
$encodingWrapperLength = \strlen('=?'.$charsetDecl.'?'.self::$encoder->getName().'??=');
|
||||
|
||||
if ($firstLineOffset >= 75) {
|
||||
//Does this logic need to be here?
|
||||
// Does this logic need to be here?
|
||||
$firstLineOffset = 0;
|
||||
}
|
||||
|
||||
@@ -226,7 +231,7 @@ abstract class AbstractHeader implements HeaderInterface
|
||||
/**
|
||||
* Generate a list of all tokens in the final header.
|
||||
*/
|
||||
protected function toTokens(string $string = null): array
|
||||
protected function toTokens(?string $string = null): array
|
||||
{
|
||||
if (null === $string) {
|
||||
$string = $this->getBodyAsString();
|
||||
|
||||
2
vendor/symfony/mime/Header/Headers.php
vendored
2
vendor/symfony/mime/Header/Headers.php
vendored
@@ -190,7 +190,7 @@ final class Headers
|
||||
return array_shift($values);
|
||||
}
|
||||
|
||||
public function all(string $name = null): iterable
|
||||
public function all(?string $name = null): iterable
|
||||
{
|
||||
if (null === $name) {
|
||||
foreach ($this->headers as $name => $collection) {
|
||||
|
||||
@@ -44,9 +44,9 @@ final class MailboxListHeader extends AbstractHeader
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws RfcComplianceException
|
||||
*
|
||||
* @return Address[]
|
||||
*
|
||||
* @throws RfcComplianceException
|
||||
*/
|
||||
public function getBody(): array
|
||||
{
|
||||
@@ -99,9 +99,9 @@ final class MailboxListHeader extends AbstractHeader
|
||||
/**
|
||||
* Gets the full mailbox list of this Header as an array of valid RFC 2822 strings.
|
||||
*
|
||||
* @throws RfcComplianceException
|
||||
*
|
||||
* @return string[]
|
||||
*
|
||||
* @throws RfcComplianceException
|
||||
*/
|
||||
public function getAddressStrings(): array
|
||||
{
|
||||
|
||||
@@ -85,7 +85,7 @@ final class ParameterizedHeader extends UnstructuredHeader
|
||||
* This doesn't need to be overridden in theory, but it is for implementation
|
||||
* reasons to prevent potential breakage of attributes.
|
||||
*/
|
||||
protected function toTokens(string $string = null): array
|
||||
protected function toTokens(?string $string = null): array
|
||||
{
|
||||
$tokens = parent::toTokens(parent::getBodyAsString());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user