improve waiting time to find a match
fix bugs