Skip to content

Commit

Permalink
bot: fix cs [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
kbond committed Feb 1, 2024
1 parent fdb23a3 commit 59db1e7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/Image/Transformer/FileTransformer.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public static function normalizeFilter(callable|object $filter): callable
}

/**
* @return Transformer\T
* @return T
*/
abstract protected function object(\SplFileInfo $image): object;

Expand All @@ -65,7 +65,7 @@ abstract protected function object(\SplFileInfo $image): object;
abstract protected static function expectedClass(): string;

/**
* @param Transformer\T $object
* @param T $object
* @param array{format:string,output:string}|array<string,mixed> $options
*/
abstract protected function save(object $object, array $options): void;
Expand Down
10 changes: 5 additions & 5 deletions src/Image/Transformer/MultiTransformer.php
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,11 @@ private function get(string $class): Transformer
private static function defaultTransformer(string $class): Transformer
{
return self::$defaultTransformers[$class] ??= match ($class) { // @phpstan-ignore-line
\GdImage::class => new Transformer\GdImageTransformer(),
\Imagick::class => new Transformer\ImagickTransformer(),
ImagineImage::class, GdImagineImage::class, ImagickImagineImage::class, GmagickImagineImage::class => Transformer\ImagineTransformer::createFor($class),
InterventionImage::class => new Transformer\InterventionTransformer(),
SpatieImage::class => new Transformer\SpatieImageTransformer(),
\GdImage::class => new GdImageTransformer(),
\Imagick::class => new ImagickTransformer(),
ImagineImage::class, GdImagineImage::class, ImagickImagineImage::class, GmagickImagineImage::class => ImagineTransformer::createFor($class),
InterventionImage::class => new InterventionTransformer(),
SpatieImage::class => new SpatieImageTransformer(),
default => throw new \InvalidArgumentException(\sprintf('No transformer available for "%s".', $class)),
};
}
Expand Down

0 comments on commit 59db1e7

Please sign in to comment.