forcedotcom / SalesforceMobileSDK-Templates

BSD 3-Clause "New" or "Revised" License
52 stars 56 forks source link

Switch user problem with SceneDelegate #286

Closed elvarliiv closed 4 years ago

elvarliiv commented 4 years ago

Hi.

I am working on a iOS project where we use both AppDelegate and SceneDelegate. I ran into a interesting trouble that if I switch to another user, both users Contacts will be shown in the app. (If user A has 10 contacts and user B 20 contacts, all 30 contacts are shown after switching user and resyncing data). It is very annoying problem I am having trouble to fix, so I wanted to ask if there is a possibility for you to make a sample how to set up a project with AppDelegate and SceneDelegate so that syncing works correctly after switching user. We use MobileSyncExplorerSwift as a template.

wmathurin commented 4 years ago

In 9.0 (end of year release), we will make iOS 13 the min version supported and we will update all the templates to use SceneDelegate. Until then, you should look at the iOS13 template for an example on how to properly use SceneDelegate with Mobile SDK.