added a progress callback