Fix generator error seen in logs - #140

Closes #140 

@BMartinos I fixed the generator error, its a tiny change, could you please review for me?