chrisben / imgcache.js

JS library based on the File API to cache images for offline recovery (target: cordova/phonegap & chrome)
Other
826 stars 216 forks source link

Error - URI not supported by CordovaResourceApi #130

Open rbabayoff opened 9 years ago

rbabayoff commented 9 years ago

Getting the following on Samsung Galaxy Tab 4, Android v4.4.2. Looks like the cdv:// url has 2 consecutive slashes in it.

CachedImage.onCacheError: Error: 
FileTransferError {code: 1, source: "http://res.cloudinary.com/lavaina/image/upload/c_f…H8/categories/3Eht2YccjmMsucr67/ckjgrKrknvcdi5qP4", target: "cdvfile://localhost/persistent/imgcache//15adbe98acdbcbcc6ef6fdac81d044f04d127d1e", http_status: 200, body: null…}
body: null
code: 1
exception: "URI not supported by CordovaResourceApi: cdvfile://localhost/persistent/imgcache//15adbe98acdbcbcc6ef6fdac81d044f04d127d1e"
http_status: 200
source: "http://res.cloudinary.com/lavaina/image/upload/c_fill,h_668,q_100,w_228/v1/stores/fCSdqNYrkpSedGtH8/categories/3Eht2YccjmMsucr67/ckjgrKrknvcdi5qP4"
target: "cdvfile://localhost/persistent/imgcache//15adbe98acdbcbcc6ef6fdac81d044f04d127d1e"
chrisben commented 9 years ago

It looks like indeed those two forward slashes could be a problem. Could you tell us more about what functions you called to get there?

chrisben commented 9 years ago

Check out 1.0rc2 and see if it fixes your problem.