Removing duplicated entityManager