systemVars.fileSystem.directories.document empty after App upgrade?

Hi,

I am putting images into systemVars.fileSystem.directories.document. However, after an app upgrade, the images seems to be gone.
Is this “normal” behaviour? If yes, where do I need to put the images so that they survive an app upgrade?

Thanks and best,
Jo

Hi! What do you mean by “app upgrade”? Do you mean after reinstalling the app, or something else?

Hey Mevi,

I mean an update with a new build e.g. in iOS Testflight.
No uninstall or similar, just updating to the new version.

Best,
Jo

Hmh. I asked around and indeed it should be so that images in systemVars.fileSystem.directories.document are safe, so we need to reproduce this so we can verify this as a bug. Thanks for reporting this!

Hey Mevi,

thank you. I will try to reproduce it and let you know.

Best,
Jo

@Mevi @Harri_Sarsa I now found the root cause for my issue here:
After saving a file to the document folder, I made the mistake to save the absolute path in client-side storage. At least on iOS, it looks like that the systemVars.fileSystem.directories.document can change after an update of the app to a new version so the absolute path gets invalid.
So my learning: Never work with absolute path, always use a formula with systemVars.fileSystem.directories.document + the filename.

2 Likes