Cordova file plugin - overwrite files -
as far can tell, there's no library call replace file (or folder). if use fileentry.copyto or directoryentry.copyto , destination exists, invalid_modification_err (error 9).
if delete file first, copyto works. if goes wrong? there overwrite option i've missed somewhere? or have write own code ensure copy successful before removing original?
you can add exclusive: false option parameter overwrite existing files.
example https://github.com/apache/cordova-plugin-file/blob/master/readme.md#create-a-persistent-file-
Comments
Post a Comment