diff --git a/lib/core/catcher_2.dart b/lib/core/catcher_2.dart index dc97877..238cfc0 100644 --- a/lib/core/catcher_2.dart +++ b/lib/core/catcher_2.dart @@ -663,17 +663,17 @@ class Catcher2 implements ReportModeAction { _logger.warning('Error occurred in $reportHandler: $handlerError'); return true; // Shut up warnings }).then((result) { - _logger.info('${report.runtimeType} result: $result'); - if (!result) { - _logger.warning('$reportHandler failed to report error'); - } else { + if (result) { + _logger.info('$reportHandler successfully reported an error'); _cachedReports.remove(report); + } else { + _logger.warning('$reportHandler failed to report an error'); } }).timeout( Duration(milliseconds: _currentConfig.handlerTimeout), onTimeout: () { _logger.warning( - '$reportHandler failed to report error because of timeout', + '$reportHandler failed to report an error because of timeout', ); }, ); diff --git a/lib/model/report_handler.dart b/lib/model/report_handler.dart index 694a23c..2284c80 100644 --- a/lib/model/report_handler.dart +++ b/lib/model/report_handler.dart @@ -31,4 +31,8 @@ abstract class ReportHandler { /// Check whether report mode should auto confirm without user confirmation. bool shouldHandleWhenRejected() => false; + + /// Can be overridden to provide more information about this handler. + @override + String toString() => runtimeType.toString(); }