refactor completion handler functions