fixed bug in generator

was using == for strings instead of .equals