Przeglądaj źródła

[Serializer] Fix bug when denormalize a class in cache

Joel Wurtz 14 lat temu
rodzic
commit
a56e271025
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      src/Symfony/Component/Serializer/Serializer.php

+ 1 - 1
src/Symfony/Component/Serializer/Serializer.php

@@ -80,7 +80,7 @@ class Serializer implements SerializerInterface
             throw new \LogicException('You must register at least one normalizer to be able to denormalize objects.');
         }
         if (isset($this->normalizerCache[$class][$format])) {
-            return $this->normalizerCache[$class][$format]->denormalize($data, $format);
+            return $this->normalizerCache[$class][$format]->denormalize($data, $class, $format);
         }
         $reflClass = new \ReflectionClass($class);
         foreach ($this->normalizers as $normalizer) {