Fixed a few async-related issues.