fixed entitymanager