Public Access
fix(): unwrap list of strings instead of strings in main.dart
just to show something in the UI from the api requests
This commit is contained in:
+4
-2
@@ -73,8 +73,10 @@ class _MyHomePageState extends State<MyHomePage> {
|
||||
_counter++;
|
||||
});
|
||||
}
|
||||
void show_result(Future<String> future_id) async {
|
||||
id = await future_id;
|
||||
// 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(() { });
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user