Skip to content

Commit 9e1312a

Browse files
authored
Missing Hint type (#1328)
1 parent 5594001 commit 9e1312a

10 files changed

+14
-11
lines changed

dart/lib/src/event_processor/deduplication_event_processor.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import 'dart:async';
22
import 'dart:collection';
33
import '../event_processor.dart';
4+
import '../hint.dart';
45
import '../protocol.dart';
56
import '../sentry_options.dart';
67

@@ -26,7 +27,7 @@ class DeduplicationEventProcessor extends EventProcessor {
2627
final SentryOptions _options;
2728

2829
@override
29-
FutureOr<SentryEvent?> apply(SentryEvent event, {hint}) {
30+
FutureOr<SentryEvent?> apply(SentryEvent event, {Hint? hint}) {
3031
if (event is SentryTransaction) {
3132
return event;
3233
}

dart/lib/src/event_processor/exception/io_exception_event_processor.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import 'dart:io';
22

3+
import '../../hint.dart';
34
import '../../protocol.dart';
45
import '../../sentry_options.dart';
56
import 'exception_event_processor.dart';
@@ -13,7 +14,7 @@ class IoExceptionEventProcessor implements ExceptionEventProcessor {
1314
final SentryOptions _options;
1415

1516
@override
16-
SentryEvent apply(SentryEvent event, {dynamic hint}) {
17+
SentryEvent apply(SentryEvent event, {Hint? hint}) {
1718
final throwable = event.throwable;
1819
if (throwable is HttpException) {
1920
return _applyHttpException(throwable, event);

dart/lib/src/event_processor/exception/web_exception_event_processor.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import '../../hint.dart';
12
import '../../protocol.dart';
23
import '../../sentry_options.dart';
34
import 'exception_event_processor.dart';
@@ -7,5 +8,5 @@ ExceptionEventProcessor exceptionEventProcessor(SentryOptions _) =>
78

89
class WebExcptionEventProcessor implements ExceptionEventProcessor {
910
@override
10-
SentryEvent apply(SentryEvent event, {dynamic hint}) => event;
11+
SentryEvent apply(SentryEvent event, {Hint? hint}) => event;
1112
}

dart/lib/src/scope.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ class Scope {
143143

144144
Scope(this._options);
145145

146-
Breadcrumb? _addBreadCrumbSync(Breadcrumb breadcrumb, {dynamic hint}) {
146+
Breadcrumb? _addBreadCrumbSync(Breadcrumb breadcrumb, {Hint? hint}) {
147147
// bail out if maxBreadcrumbs is zero
148148
if (_options.maxBreadcrumbs == 0) {
149149
return null;
@@ -185,7 +185,7 @@ class Scope {
185185
}
186186

187187
/// Adds a breadcrumb to the breadcrumbs queue
188-
Future<void> addBreadcrumb(Breadcrumb breadcrumb, {dynamic hint}) async {
188+
Future<void> addBreadcrumb(Breadcrumb breadcrumb, {Hint? hint}) async {
189189
final addedBreadcrumb = _addBreadCrumbSync(breadcrumb, hint: hint);
190190
if (addedBreadcrumb != null) {
191191
await _callScopeObservers((scopeObserver) async =>

dart/test/scope_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,7 @@ void main() {
617617
scopeObserver: fixture.mockScopeObserver,
618618
beforeBreadcrumbCallback: (
619619
Breadcrumb? breadcrumb, {
620-
dynamic hint,
620+
Hint? hint,
621621
}) {
622622
return breadcrumb?.copyWith(message: "modified");
623623
},

flutter/lib/src/event_processor/flutter_exception_event_processor.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import 'package:sentry/sentry.dart';
33

44
class FlutterExceptionEventProcessor implements EventProcessor {
55
@override
6-
SentryEvent apply(SentryEvent event, {dynamic hint}) {
6+
SentryEvent apply(SentryEvent event, {Hint? hint}) {
77
final exception = event.throwable;
88
if (exception is NetworkImageLoadException) {
99
return _applyNetworkImageLoadException(event, exception);

flutter/lib/src/event_processor/native_app_start_event_processor.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class NativeAppStartEventProcessor extends EventProcessor {
1818
final SentryNative _native;
1919

2020
@override
21-
FutureOr<SentryEvent?> apply(SentryEvent event, {hint}) async {
21+
FutureOr<SentryEvent?> apply(SentryEvent event, {Hint? hint}) async {
2222
final appStartEnd = _native.appStartEnd;
2323

2424
if (appStartEnd != null &&

flutter/lib/src/event_processor/screenshot_event_processor.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class ScreenshotEventProcessor extends EventProcessor {
1919
sentryScreenshotWidgetGlobalKey.currentContext != null;
2020

2121
@override
22-
FutureOr<SentryEvent?> apply(SentryEvent event, {hint}) async {
22+
FutureOr<SentryEvent?> apply(SentryEvent event, {Hint? hint}) async {
2323
if (event.exceptions == null &&
2424
event.throwable == null &&
2525
_hasSentryScreenshotWidget) {

flutter/lib/src/integrations/load_contexts_integration.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class _LoadContextsIntegrationEventProcessor extends EventProcessor {
4040
final SentryFlutterOptions _options;
4141

4242
@override
43-
FutureOr<SentryEvent?> apply(SentryEvent event, {hint}) async {
43+
FutureOr<SentryEvent?> apply(SentryEvent event, {Hint? hint}) async {
4444
try {
4545
final loadContexts = await _channel.invokeMethod('loadContexts');
4646

flutter/lib/src/integrations/load_image_list_integration.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class _LoadImageListIntegrationEventProcessor extends EventProcessor {
3636
final SentryFlutterOptions _options;
3737

3838
@override
39-
FutureOr<SentryEvent?> apply(SentryEvent event, {hint}) async {
39+
FutureOr<SentryEvent?> apply(SentryEvent event, {Hint? hint}) async {
4040
if (event.needsSymbolication()) {
4141
try {
4242
// we call on every event because the loaded image list is cached

0 commit comments

Comments
 (0)