timing bug fixed