Fixed timing issue with async