Skip to content

Commit

Permalink
Added reference URL to leaking Sinks issue in push module
Browse files Browse the repository at this point in the history
  • Loading branch information
ikurek committed Apr 27, 2022
1 parent 243c66d commit 35b784a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/src/platform/src/push_activation_events_internal.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import 'package:ably_flutter/ably_flutter.dart';
/// package-private implementation of [PushActivationEvents]
/// used internally by [Push] instances
// FIXME: StreamControllers here may leak, we should add a `close()` method
// like [PushNotificationEventsInternal.close()]
// See: https://github.com/ably/ably-flutter/issues/382
class PushActivationEventsInternal extends PushActivationEvents {
/// [StreamController] used to handle onActivate events
StreamController<ErrorInfo?> onActivateStreamController = StreamController();
Expand Down
3 changes: 2 additions & 1 deletion lib/src/platform/src/push_notification_events_internal.dart
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ class PushNotificationEventsInternal implements PushNotificationEvents {
}

/// Used to close internal [StreamController] instances
// FIXME: This method is not called anywhere, and it probably should be
// FIXME: This method is not called anywhere
// See: https://github.com/ably/ably-flutter/issues/382
void close() {
onMessageStreamController.close();
onNotificationTapStreamController.close();
Expand Down

0 comments on commit 35b784a

Please sign in to comment.