Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/connectivity/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.4.5+4

* Stability and Maintainability: update documentations.

## 0.4.5+3

* Remove AndroidX warnings.
Expand Down
8 changes: 0 additions & 8 deletions packages/connectivity/example/README.md

This file was deleted.

3 changes: 3 additions & 0 deletions packages/connectivity/lib/connectivity.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import 'package:meta/meta.dart';
/// None: Device not connected to any network
enum ConnectivityResult { wifi, mobile, none }

/// Discover network connectivity configurations: Distinguish between WI-FI and cellular, check WI-FI status and more.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would comment the @visibleForTesting things too, just to be safe. It's fine for the comment just to say something like "This is just exposed for testing purposes and should not be altered by users of the plugin."

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Going to land with this change.

class Connectivity {
/// Constructs a singleton instance of [Connectivity].
///
Expand All @@ -35,11 +36,13 @@ class Connectivity {

Stream<ConnectivityResult> _onConnectivityChanged;

/// Exposed for testing purposes and should not be used by users of the plugin.
@visibleForTesting
static const MethodChannel methodChannel = MethodChannel(
'plugins.flutter.io/connectivity',
);

/// Exposed for testing purposes and should not be used by users of the plugin.
@visibleForTesting
static const EventChannel eventChannel = EventChannel(
'plugins.flutter.io/connectivity_status',
Expand Down
2 changes: 1 addition & 1 deletion packages/connectivity/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: Flutter plugin for discovering the state of the network (WiFi &
mobile/cellular) connectivity on Android and iOS.
author: Flutter Team <[email protected]>
homepage: https://github.com/flutter/plugins/tree/master/packages/connectivity
version: 0.4.5+3
version: 0.4.5+4

flutter:
plugin:
Expand Down