chore(formatting): autoformats and adaptations

This commit is contained in:
fbachus
2026-06-06 01:22:36 +02:00
parent c581800298
commit 5fd3e8faad
2 changed files with 18 additions and 16 deletions
+10 -7
View File
@@ -73,11 +73,12 @@ class _MyHomePageState extends State<MyHomePage> {
_counter++;
});
}
// TODO :find a better way to show the list
void show_result(Future<List<String>> future_id) async {
var tmp = await future_id;
id = tmp[0];
setState(() { });
setState(() {});
}
@override
@@ -123,12 +124,14 @@ class _MyHomePageState extends State<MyHomePage> {
style: Theme.of(context).textTheme.headlineMedium,
),
Text('API key from ENV is $API_KEY'),
MaterialButton(onPressed: () { show_result(ApiHandler.findStations('S Biesdorf')); setState(() {}); },
child: Text(
'Search for \'S Biesdorf\''
),
MaterialButton(
onPressed: () {
show_result(ApiHandler.findStations('S Biesdorf'));
setState(() {});
},
child: Text('Search for \'S Biesdorf\''),
),
Text(id)
Text(id),
],
),
),
@@ -139,4 +142,4 @@ class _MyHomePageState extends State<MyHomePage> {
),
);
}
}
}