Skip to content

Commit 8dea5df

Browse files
authored
Ensure that Nyholm PSR17 factory is fully available
1 parent e12cb05 commit 8dea5df

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

Slim/Factory/Psr17/NyholmPsr17Factory.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,15 @@ public static function getServerRequestCreator(): ServerRequestCreatorInterface
3333

3434
return new ServerRequestCreator($serverRequestCreator, static::$serverRequestCreatorMethod);
3535
}
36+
37+
/**
38+
* {@inheritdoc}
39+
*/
40+
public static function isServerRequestCreatorAvailable(): bool
41+
{
42+
return (
43+
parent::isServerRequestCreatorAvailable()
44+
&& class_exists(static::$responseFactoryClass)
45+
);
46+
}
3647
}

0 commit comments

Comments
 (0)