I am using the flutter file picker 6.0.0.When i try to select file from the picker file.I used singleInstance in manifest.
FilePickerResult? result = await FilePicker.platform.pickFiles(allowedExtensions: ['jpg','jpeg','png','pdf'],type: FileType.custom);
if (result != null) {
File file = File(result.files.single.path!);
controller.isPasswordProtected.value =
await FileHelper.checkFileIsPasswordProtected(file);
controller.fileSelected(file);
controller.uploadDocument();
}