forked from firka/flutter
more UI-as-code (#35516)
This commit is contained in:
committed by
GitHub
parent
d03aecab58
commit
df4bf453ab
@@ -1123,12 +1123,11 @@ void _unhandledJsonRpcError(dynamic error, dynamic stack) {
|
||||
|
||||
String _getWebSocketUrl(String url) {
|
||||
Uri uri = Uri.parse(url);
|
||||
final List<String> pathSegments = <String>[];
|
||||
// If there's an authentication code (default), we need to add it to our path.
|
||||
if (uri.pathSegments.isNotEmpty) {
|
||||
pathSegments.add(uri.pathSegments.first);
|
||||
}
|
||||
pathSegments.add('ws');
|
||||
final List<String> pathSegments = <String>[
|
||||
// If there's an authentication code (default), we need to add it to our path.
|
||||
if (uri.pathSegments.isNotEmpty) uri.pathSegments.first,
|
||||
'ws',
|
||||
];
|
||||
if (uri.scheme == 'http')
|
||||
uri = uri.replace(scheme: 'ws', pathSegments: pathSegments);
|
||||
return uri.toString();
|
||||
|
||||
@@ -5,7 +5,7 @@ author: Flutter Authors <flutter-dev@googlegroups.com>
|
||||
|
||||
environment:
|
||||
# The pub client defaults to an <2.0.0 sdk constraint which we need to explicitly overwrite.
|
||||
sdk: ">=2.0.0-dev.68.0 <3.0.0"
|
||||
sdk: ">=2.2.2 <3.0.0"
|
||||
|
||||
dependencies:
|
||||
file: 5.0.10
|
||||
|
||||
Reference in New Issue
Block a user