From 26e0e215cf3d17d87bf2e8a6986913fb96a34480 Mon Sep 17 00:00:00 2001 From: Brett Morgan Date: Tue, 8 Jun 2021 09:51:44 +1000 Subject: [PATCH] Adjust flutter_maps_firestore's lint rules (#821) --- flutter_maps_firestore/analysis_options.yaml | 1 - flutter_maps_firestore/lib/main.dart | 7 ++++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/flutter_maps_firestore/analysis_options.yaml b/flutter_maps_firestore/analysis_options.yaml index 30ac27228..85f6fbe91 100644 --- a/flutter_maps_firestore/analysis_options.yaml +++ b/flutter_maps_firestore/analysis_options.yaml @@ -17,4 +17,3 @@ linter: test_types_in_equals: true throw_in_finally: true unnecessary_statements: true - use_key_in_widget_constructors: false diff --git a/flutter_maps_firestore/lib/main.dart b/flutter_maps_firestore/lib/main.dart index f2fcf0fe3..7fd24f807 100644 --- a/flutter_maps_firestore/lib/main.dart +++ b/flutter_maps_firestore/lib/main.dart @@ -22,10 +22,12 @@ final _placesApiClient = GoogleMapsPlaces(apiKey: googleMapsApiKey); Future main() async { WidgetsFlutterBinding.ensureInitialized(); await Firebase.initializeApp(); - runApp(App()); + runApp(const App()); } class App extends StatelessWidget { + const App({Key? key}) : super(key: key); + @override Widget build(BuildContext context) { return MaterialApp( @@ -40,8 +42,7 @@ class App extends StatelessWidget { } class HomePage extends StatefulWidget { - const HomePage({required this.title}); - + const HomePage({required this.title, Key? key}) : super(key: key); final String title; @override