fixed bug with progress bar