Add generation only for one entity and clean code