switched handling to asynchronous