0

I have a document where I used to have a field that stores a string, but I now I want to change it to store hashes. The problem is with the old documents when I try to retrieve one of those, I get the following error:

Catchable Fatal Error: Argument 2 passed to Doctrine\ODM\MongoDB\UnitOfWork::getClassNameForAssociation() must be of the type array, string given, called in /vagrant/wowfi/app/cache/dev/doctrine/odm/mongodb/Hydrators/WowfiCoreBundleDocumentLoginUserHydrator.php on line 82 and defined

I read in the documentation that if I want to store different types of documents, I should use a discriminator. But in my case, I don't have 2 differente classes, it's just have one Document Class where I changed the field type from string to a hash (Embedded document).

Thanks for your help.

PachinSV
  • 3,680
  • 2
  • 29
  • 41

1 Answers1

0

I started using another field name, instead of "recycle" the old field name.

PachinSV
  • 3,680
  • 2
  • 29
  • 41