Skip to content

Commit 34c4e11

Browse files
authored
Update exception_type_identifier.dart
1 parent 745a18f commit 34c4e11

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

dart/lib/src/exception_type_identifier.dart

+5-7
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
/// An abstract class for identifying the type of Dart errors and exceptions.
22
///
3-
/// This class provides a contract for implementing error type identification
4-
/// in Dart. It's used in scenarios where error types need to be
5-
/// determined in obfuscated builds, as [runtimeType] is not reliable in
6-
/// such cases.
3+
/// It's used in scenarios where error types need to be determined in obfuscated builds
4+
/// as [runtimeType] is not reliable in such cases.
75
///
86
/// Implement this class to create custom error type identifiers for errors or exceptions.
97
/// that we do not support out of the box.
@@ -12,10 +10,10 @@
1210
///
1311
/// Example:
1412
/// ```dart
15-
/// class MyErrorTypeIdentifier implements ErrorTypeIdentifier {
13+
/// class MyExceptionTypeIdentifier implements ExceptionTypeIdentifier {
1614
/// @override
17-
/// String? identifyType(dynamic error) {
18-
/// if (error is MyCustomError) return 'MyCustomError';
15+
/// String? identifyType(dynamic throwable) {
16+
/// if (throwable is MyCustomError) return 'MyCustomError';
1917
/// return null;
2018
/// }
2119
/// }

0 commit comments

Comments
 (0)