fixing heisenbug