fix generator problems