fixed delay bug