Revert last commit. It results in an infinite progressDialog