Skip to content

Commit c14795d

Browse files
committed
fix: add allowCompression default to true and fix null safety
1 parent bb7fc6f commit c14795d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/src/form_builder_file_picker.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ class _FormBuilderFilePickerState
158158
resultList = await FilePicker.platform.pickFiles(
159159
type: widget.type,
160160
allowedExtensions: widget.allowedExtensions,
161-
allowCompression: widget.allowCompression,
161+
allowCompression: widget.allowCompression ?? true,
162162
onFileLoading: widget.onFileLoading,
163163
allowMultiple: widget.allowMultiple,
164164
withData: widget.withData,
@@ -239,7 +239,7 @@ class _FormBuilderFilePickerState
239239
width: double.infinity,
240240
color: Colors.white.withOpacity(.8),
241241
child: Text(
242-
files[index].name!,
242+
files[index].name,
243243
style: theme.textTheme.caption,
244244
maxLines: 2,
245245
overflow: TextOverflow.clip,

0 commit comments

Comments
 (0)