Skip to content
This repository has been archived by the owner on May 9, 2018. It is now read-only.

RMTileCache in Documents #641

Open
trdavidson opened this issue Jun 1, 2015 · 2 comments
Open

RMTileCache in Documents #641

trdavidson opened this issue Jun 1, 2015 · 2 comments

Comments

@trdavidson
Copy link

When using the offline-maps example, the RMTileCache of the Map appears in the Documents folder. This will immediately cause a rejection in the App Store. We are getting ready to ship our App for production and wanted to ask how to change this behaviour for RMTileCache. Thanks!

@username0x0a
Copy link

I've been dealing with this as well in our project. You can temporarily disable iCloud sync:

[[NSURL fileURLWithPath:[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) firstObject]]
    setResourceValue:[NSNumber numberWithBool:YES]
        forKey:NSURLIsExcludedFromBackupKey error:nil];

for the whole Documents folder or for a specific path by modifying the code above; your app will stop syncing the provided path and should become review-compliant. Otherwise you can customize this path in Mapbox component source. AFAIK there's no programatic way to change this at this moment.

@jcarbaugh
Copy link

I haven't tried this myself, but you should be able change the cache path from Documents to Caches with routeme.plist. See the example plist on the SDK page under "File-based cache configuration" where useCachesDirectory gets set to true.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants