refactory asyncTasks