Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SerializationApi has bug in iOS #174

Open
abbasalim opened this issue Nov 14, 2023 · 3 comments
Open

SerializationApi has bug in iOS #174

abbasalim opened this issue Nov 14, 2023 · 3 comments

Comments

@abbasalim
Copy link

Hi,
SerializationApi has bug in iOS, need to restart app to get new data.

@russhwolf
Copy link
Owner

Can you give any more detail? This gives me nothing I can act on.

What does your code look like? What version are you using? What specifically are you trying to do, what do you expect to happen, and what happens instead?

@abbasalim
Copy link
Author

multiplatformSettingsNoArg = "1.1.0" multiplatformSettingsSerialization = "1.1.0"

in the first screen of my app, we save user info if this is null, with :
fun setAuthUser(userModel: UserModel){ settings.encodeValue(UserModel.serializer(), Keys.USER.value, userModel) }

after in next screen we load data with :
fun user(): UserModel? { return settings.decodeValueOrNull(UserModel.serializer(),Keys.USER.value) }

and show to user with
val userName = mutableStateOf(authHelper.user()?.name)

in android and desktop worked fine but in iOS
when saved data in first time, showed this when restart app

@russhwolf
Copy link
Owner

Sorry this has been hanging for so long. Is this still an issue for you? The information you've given isn't enough for me to reproduce the problem.

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

No branches or pull requests

2 participants