fixing simple generator