update WaitGroup