Skip to content

Commit

Permalink
🐛 Change directory
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexV525 committed Aug 1, 2023
1 parent 7f4e89f commit 9389854
Showing 1 changed file with 9 additions and 11 deletions.
20 changes: 9 additions & 11 deletions example/lib/customs/pickers/directory_file_asset_picker.dart
Original file line number Diff line number Diff line change
Expand Up @@ -290,17 +290,15 @@ class FileAssetPickerProvider extends AssetPickerProvider<File, Directory> {
Future<void> getPaths() async {
currentAssets = <File>[];
paths.clear();
final Directory? directory = await getExternalStorageDirectory();
if (directory != null) {
final PathWrapper<Directory> wrapper = PathWrapper<Directory>(
path: directory,
thumbnailData: await getThumbnailFromPath(
PathWrapper<Directory>(path: directory),
),
);
paths.add(wrapper);
currentPath = wrapper;
}
final Directory directory = await getApplicationDocumentsDirectory();
final PathWrapper<Directory> wrapper = PathWrapper<Directory>(
path: directory,
thumbnailData: await getThumbnailFromPath(
PathWrapper<Directory>(path: directory),
),
);
paths.add(wrapper);
currentPath = wrapper;
}

@override
Expand Down

0 comments on commit 9389854

Please sign in to comment.