working on progress bar edge cases