markmarijnissen / cordova-file-cache

An awesome File Cache for Cordova Apps.
MIT License
87 stars 29 forks source link

differing permission handling #11

Open ghost opened 8 years ago

ghost commented 8 years ago

I've noticed on oldish HTC One, this statement (in the README) is true:

The plugin requests user permission to use persistent storage at the application first start.

On a newer Nexus, the app doesn't prompt for it at load time, and it doesn't even prompt for it the first time it's used. Further, even after denying the permission, methods from CordovaFileCache.js still seem to work -- download/get/ready/toURL/clear all fine.

So, what exactly is the file permission doing? Is there any way to entirely avoid it?

ghost commented 8 years ago

instantiating CordovaFileCache & CordovaPromiseFS here:

  cache: new CordovaFileCache({
    fs: new CordovaPromiseFS({
      Promise: Bluebird,
      persistent: true
    }),
    serverRoot: $server_hostname + '/assets/',
    localRoot: 'data',
    cacheBuster: false
  }),
markmarijnissen commented 8 years ago

What README are you referring to?