Skip to content
This repository has been archived by the owner on Nov 9, 2021. It is now read-only.

[Blocker] resolveNativePath is failing in android 11 #76

Open
sahalshn opened this issue Nov 8, 2021 · 2 comments
Open

[Blocker] resolveNativePath is failing in android 11 #76

sahalshn opened this issue Nov 8, 2021 · 2 comments

Comments

@sahalshn
Copy link

sahalshn commented Nov 8, 2021

cordova-plugin-filechooser 1.2.0 "File Chooser"
cordova-plugin-filepath 1.6.0 "cordova-plugin-filepath"

Unable to read file native path in android 11. This is only happening for files that are uploaded from the download folder.

this.fileChooser.open()
        .then(uri => {
          let pdfname = uri.substring(uri.lastIndexOf("/") + 1);
          let pdfExt = pdfname.substr(pdfname.lastIndexOf('.') + 1);
          if (pdfExt == 'pdf') {
            // let name = pdfname.split('.').slice(0, -1).join('.');
            this.processPDF(uri, '');
          }
          else {
            this.filePath.resolveNativePath(uri)
              .then(file => {
                let filename = file.substring(file.lastIndexOf("/") + 1);
                let fileExt = filename.substr(filename.lastIndexOf('.') + 1);
                if (fileExt == 'pdf') {
                  
                }
               
              })
              .catch(err => {
                // Here err is {code: 0, message: 'Unable to resolve filesystem path. hahahha'}
              });
          }
        })
@sahalshn
Copy link
Author

sahalshn commented Nov 9, 2021

@hiddentao Can you please have look into it

@hiddentao
Copy link
Owner

@sahalshn I am no longer actively maintaining this repo

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants