Realm at path ... already opened with different sync user

Hi @Jimmi_Andersen,

As explained above, the standard path for a realm does include the user id:

If you’re overriding the local path to a fixed default.realm, you’re skipping the logic that would isolate the different users, and there’ll be conflicts when you log one out and another in. Additionally, please note that logOut doesn’t close the opened realm(s) immediately, to be safe you should explicitly nil all the references to each realm (including observers, cursors, …) and leave some time for the different threads to close properly.

1 Like