some more refactoring of async tasks