async task refactored