This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
The following code was written by using NetBeans refactoring, code completion of a "for Object" loop. At the place after typing entityManager.persist I let the IDE complete again. I would expect that the IDE inserts "customer" as the last Object in scope not "this". I see this quite often and I get the feeling that there is a potential for improvement here. public void saveCustomers(List<Customer> customers) { for (Customer customer : customers) { entityManager.persist(this);// should be customers } }