replace specific php7 code
This commit is contained in:
parent
9447e66da1
commit
1c15d249b3
@ -97,7 +97,7 @@ class Swift_Mime_Headers_ParameterizedHeader extends Swift_Mime_Headers_Unstruct
|
|||||||
{
|
{
|
||||||
$params = $this->getParameters();
|
$params = $this->getParameters();
|
||||||
|
|
||||||
return $params[$parameter] ?? null;
|
return isset($params[$parameter]) ? $params[$parameter] : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -493,7 +493,7 @@ class Swift_Mime_SimpleMessage extends Swift_Mime_MimePart
|
|||||||
'%[1-5]'
|
'%[1-5]'
|
||||||
);
|
);
|
||||||
|
|
||||||
return $priority ?? 3;
|
return isset($priority) ? $priority : 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -293,7 +293,7 @@ class Swift_Mime_SimpleMimeEntity implements Swift_Mime_CharsetObserver, Swift_M
|
|||||||
public function setChildren(array $children, $compoundLevel = null)
|
public function setChildren(array $children, $compoundLevel = null)
|
||||||
{
|
{
|
||||||
// TODO: Try to refactor this logic
|
// TODO: Try to refactor this logic
|
||||||
$compoundLevel = $compoundLevel ?? $this->getCompoundLevel($children);
|
$compoundLevel = isset($compoundLevel) ? $compoundLevel : $this->getCompoundLevel($children);
|
||||||
$immediateChildren = array();
|
$immediateChildren = array();
|
||||||
$grandchildren = array();
|
$grandchildren = array();
|
||||||
$newContentType = $this->userContentType;
|
$newContentType = $this->userContentType;
|
||||||
|
|||||||
@ -159,7 +159,7 @@ class Swift_Plugins_DecoratorPlugin implements Swift_Events_SendListener, Swift_
|
|||||||
return $this->replacements->getReplacementsFor($address);
|
return $this->replacements->getReplacementsFor($address);
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->replacements[$address] ?? null;
|
return isset($this->replacements[$address]) ? $this->replacements[$address] : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -208,7 +208,7 @@ class Swift_Transport_EsmtpTransport extends Swift_Transport_AbstractSmtpTranspo
|
|||||||
*/
|
*/
|
||||||
public function getSourceIp()
|
public function getSourceIp()
|
||||||
{
|
{
|
||||||
return $this->params['sourceIp'] ?? null;
|
return isset($this->params['sourceIp']) ? $this->params['sourceIp'] : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user