imgcache.js icon indicating copy to clipboard operation
imgcache.js copied to clipboard

Can't save files in iOS 9: Permission error

Open sidferreira opened this issue 9 years ago • 5 comments

The app is done but this error just started out. Can anyone help me on that? I'm looking for help on Apache's Jira too Basically imgcache says that everything os OK, but when I try to save the file I get a permission error.

] INFO: LocalFileSystem opened
] INFO: Local cache folder opened: /imgcache/
] INFO: com.apple.MobileBackup metadata set
] $state.go('app.discover');
] FileTransferError {
    body = "Could not create path to save downloaded file: You don\U2019t have permission to save the file \U201cimgcache\U201d in the folder \U201cDonner12H321.N78OS\U201d.";
    code = 1;
    "http_status" = 200;
    source = "http://mlb-s2-p.mlstatic.com/acessorios-garrafas-en-ciclismo-398401-MLB20329596893_062015-S.jpg";
    target = "cdvfile://localhost/root/imgcache/54b908737cfb2c20dd013d96eb5c496437c49768.jpg";
}
] File Transfer Error: Could not create path to save downloaded file: You don’t have permission to save the file “imgcache” in the folder “Donner12H321.N78OS”.
] ERROR: Download error source: http://mlb-s2-p.mlstatic.com/acessorios-garrafas-en-ciclismo-398401-MLB20329596893_062015-S.jpg
] ERROR: Download error target: cdvfile://localhost/root/imgcache/54b908737cfb2c20dd013d96eb5c496437c49768.jpg
] ERROR: Download error code: 1

sidferreira avatar Dec 02 '15 19:12 sidferreira

same here, looks like duplicate issue #145 ?

JumpLink avatar Dec 08 '15 18:12 JumpLink

I commented out this part and worked. Line 164 of bower version at that time.

if (device.platform.toLowerCase() == "ios") {
    return entry.fullPath
}

sidferreira avatar Dec 09 '15 18:12 sidferreira

1.0rc2 solves this problem.

SamVerschueren avatar Jan 06 '16 13:01 SamVerschueren

@SidFerreira could you check whether 1.0rc2 fixes your problem as well?

chrisben avatar Jan 24 '16 15:01 chrisben

Just needed to replace the following line for Store : store = cordova.file.dataDirectory;

and worked like a charm for me. Hope this helps..

jslamba0811 avatar Apr 08 '16 09:04 jslamba0811