Fix usage of getRequiredPackage, closes #10052
parent
b232ee6663
commit
cfe718fa43
|
@ -76,6 +76,9 @@ abstract class Rule
|
|||
return $this->reasonData;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return ?string
|
||||
*/
|
||||
public function getRequiredPackage()
|
||||
{
|
||||
$reason = $this->getReason();
|
||||
|
|
|
@ -108,7 +108,8 @@ class SolverProblemsException extends \RuntimeException
|
|||
{
|
||||
foreach ($reasonSets as $reasonSet) {
|
||||
foreach ($reasonSet as $rule) {
|
||||
if (0 === strpos($rule->getRequiredPackage(), 'ext-')) {
|
||||
$required = $rule->getRequiredPackage();
|
||||
if (null !== $required && 0 === strpos($required, 'ext-')) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue