psalm-plugin-symfony icon indicating copy to clipboard operation
psalm-plugin-symfony copied to clipboard

QueryBuilderSetParameter error when using an entity with no specified type

Open pkly opened this issue 4 years ago • 0 comments

Doctrine has some special handling where it looks up the primary key of the object if said object is an entity that's known to it, and to keep this behavior you cannot specify a type. It looks much neater in terms of usage than ->setParameter('something', $entity->getId(), Types::INTEGER);, and isn't really an error, and as such I'd like to ask for an opt-in feature that will silently ignore this scenario.

pkly avatar Sep 16 '21 11:09 pkly