Refactored and wrote async methods