Added new method sendReportOnExit and changed the way onSendCallback is handled