Flutter_file_picker: Upgrade ASAP to flutter 2.0.0

Created on 3 Mar 2021  路  11Comments  路  Source: miguelpruivo/flutter_file_picker

Flutter 2.0.0 request flutter_plugin_android_lifecycle ^1.0.6 and it's not possible to upgrade to use flutter 2.0.0 and file picker as file picker is still not prepared for Flutter 2.

new issue

Most helpful comment

../../../../../.pub-cache/hosted/pub.dartlang.org/file_picker-3.0.0-nullsafety.3/lib/src/file_picker_result.dart:27:8: Error: A value of type 'List' can't be returned from a function with return type 'List' because 'String?' is nullable and 'String' isn't.
'List' is from 'dart:core'.
.toList();

All 11 comments

BTW: really thanks for this component. :-D

plugin_platform_interface too

Dup of #621. I'll update it today.

VALEU!!!! :-) Need help? Precisa ajuda? Necesitas ayuda? :-)

@phackwer no problem, it's already done. But thank you for the availability. 馃槂

Published with 3.0.0-nullsafety.3. Let me know if it's working for you.

Thank you.

Not working unfortunately @miguelpruivo .

It's just a small change in Line 22 of file_picker_result.dart:
List<String?> get paths => files

../../../../../.pub-cache/hosted/pub.dartlang.org/file_picker-3.0.0-nullsafety.3/lib/src/file_picker_result.dart:27:8: Error: A value of type 'List' can't be returned from a function with return type 'List' because 'String?' is nullable and 'String' isn't.
'List' is from 'dart:core'.
.toList();

Following

Sorry, I misread image_picker as file_picker. Just woke up and still "booting", hahahaha.

@pablo-threadable just upgrade to image_picker: ^0.7.2

Yeah I realised my error just after a cup of coffee. :-D

Was this page helpful?
0 / 5 - 0 ratings