You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have this line : $this->entity->translate($locale)->$fieldName ?? ''; and $entity is declared with two interfaces : protected TranslatableInterface&ExposeTranslatableFieldsInterface $entity,. So when StaticTranslationTypeHelper::getTranslationClass is used, you will get the first reference class : $translatableClass = $type->getReferencedClasses()[0];. Unfortunately, the class ExposeTranslatableFieldsInterface is the first in the array...
I can code the correction. Maybe, a foreach ? I will try this.
It's still broken today, took us some time to find out why we suddenly got a crash after adding phpstan/extension-installer until we noticed this library has its own extension integrated. Shouldn't it be a separate library anyway?
I tried to fix, but my change will move some functionalities. I don't know if this will pass... It's not a simple change, but I don't know the project so...
I there,
I'm using translatable from Knp and I have this error :
I have this in my composer.json :
So the file
vendor/knplabs/doctrine-behaviors/phpstan-extension.neon
is already included (related to #516How can I fix it ?
The text was updated successfully, but these errors were encountered: