1
0
mirror of https://github.com/danog/amp.git synced 2024-12-02 09:27:46 +01:00

Remove fallback part from error messages

This commit is contained in:
Niklas Keller 2017-05-19 16:51:20 +02:00
parent 28bb6068f1
commit e589f2d935

View File

@ -40,14 +40,14 @@ class DriverFactory {
if (!\class_exists($driver)) { if (!\class_exists($driver)) {
throw new \Error(\sprintf( throw new \Error(\sprintf(
"Driver '%s' does not exist, falling back to default driver.", "Driver '%s' does not exist.",
$driver $driver
)); ));
} }
if (!\is_subclass_of($driver, Driver::class)) { if (!\is_subclass_of($driver, Driver::class)) {
throw new \Error(\sprintf( throw new \Error(\sprintf(
"Driver '%s' is not a subclass of '%s', falling back to default driver.", "Driver '%s' is not a subclass of '%s'.",
$driver, $driver,
Driver::class Driver::class
)); ));