StaticFactory :: lint

This commit is contained in:
Atakan Demircioğlu
2022-07-19 09:01:15 +03:00
parent 54f809298b
commit 719593cedc

View File

@@ -14,7 +14,7 @@ final class StaticFactory
{ {
public static function factory(string $type): Formatter public static function factory(string $type): Formatter
{ {
return match($type) { return match ($type) {
'number' => new FormatNumber(), 'number' => new FormatNumber(),
'string' => new FormatString(), 'string' => new FormatString(),
default => throw new InvalidArgumentException('Unknown format given'), default => throw new InvalidArgumentException('Unknown format given'),