From 1b4eb70c3505135eeefd60c4fe475cba2fd5ea4d Mon Sep 17 00:00:00 2001 From: Kevin Moore Date: Wed, 10 Jul 2024 08:31:43 -0700 Subject: [PATCH] Dart: update dependencies and fixes for latest lints (#6050) --- .../community/serving/helloworld-dart/bin/server.dart | 3 ++- code-samples/community/serving/helloworld-dart/pubspec.yaml | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/code-samples/community/serving/helloworld-dart/bin/server.dart b/code-samples/community/serving/helloworld-dart/bin/server.dart index d6d2b1b3d..87e8f26f2 100644 --- a/code-samples/community/serving/helloworld-dart/bin/server.dart +++ b/code-samples/community/serving/helloworld-dart/bin/server.dart @@ -23,7 +23,8 @@ void main(List args) async { final ip = InternetAddress.anyIPv4; // Configure a pipeline that logs requests. - final handler = Pipeline().addMiddleware(logRequests()).addHandler(_router); + final handler = + Pipeline().addMiddleware(logRequests()).addHandler(_router.call); // For running in containers, we respect the PORT environment variable. final port = int.parse(Platform.environment['PORT'] ?? '8080'); diff --git a/code-samples/community/serving/helloworld-dart/pubspec.yaml b/code-samples/community/serving/helloworld-dart/pubspec.yaml index d4b324270..52303ec85 100644 --- a/code-samples/community/serving/helloworld-dart/pubspec.yaml +++ b/code-samples/community/serving/helloworld-dart/pubspec.yaml @@ -2,7 +2,7 @@ name: hello_world_dart publish_to: none # Avoid accidentally publishing this to pub.dev environment: - sdk: ^3.0.0 + sdk: ^3.1.0 dependencies: args: ^2.3.0 @@ -10,6 +10,6 @@ dependencies: shelf_router: ^1.1.0 dev_dependencies: - http: ^0.13.0 - lints: ^2.0.0 + http: ^1.0.0 + lints: ^4.0.0 test: ^1.21.0