lint: Fix invalid assignment

Fix error: A value of type 'dynamic' can't be assigned to a variable
of type 'int'.
(invalid_assignment at [sanmill] lib/shared/picker.dart:76)
This commit is contained in:
Calcitem 2021-10-16 13:32:41 +08:00 committed by GitHub
parent 4df5dcd96d
commit 8d2afa2a5d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -71,9 +71,9 @@ Future<int> showPickerNumber(
),
onConfirm: (Picker picker, List value) async {
debugPrint(value.toString());
final selectValues = picker.getSelectedValues();
final List selectValues = picker.getSelectedValues();
debugPrint(selectValues.toString());
selectValue = selectValues[0];
selectValue = selectValues[0] as int;
},
).showDialog(context);