Skip to content

Commit

Permalink
Merge d218b3e into 93e45fc
Browse files Browse the repository at this point in the history
  • Loading branch information
alanpoulain committed Feb 15, 2021
2 parents 93e45fc + d218b3e commit 9ce00e4
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -14,6 +14,7 @@
namespace ApiPlatform\Core\Tests\Fixtures\TestBundle\DataTransformer;

use ApiPlatform\Core\DataTransformer\DataTransformerInterface;
use ApiPlatform\Core\Tests\Fixtures\TestBundle\Document\RPC as RPCDocument;
use ApiPlatform\Core\Tests\Fixtures\TestBundle\Dto\RPCOutput;
use ApiPlatform\Core\Tests\Fixtures\TestBundle\Entity\RPC;

Expand All @@ -32,6 +33,6 @@ public function transform($object, string $to, array $context = [])
*/
public function supportsTransformation($object, string $to, array $context = []): bool
{
return $object instanceof RPC && RPCOutput::class === $to;
return ($object instanceof RPC || $object instanceof RPCDocument) && RPCOutput::class === $to;
}
}

0 comments on commit 9ce00e4

Please sign in to comment.