bugfix for while loop