Map capture working except for error handling.