Skip to content
This repository has been archived by the owner on Mar 19, 2024. It is now read-only.

Polymorphic serializer Error #85

Open
hmshohrab opened this issue Aug 19, 2023 · 2 comments
Open

Polymorphic serializer Error #85

hmshohrab opened this issue Aug 19, 2023 · 2 comments

Comments

@hmshohrab
Copy link

hmshohrab commented Aug 19, 2023

When I use "minifyEnabled true" that error message is thrown...

kotlinx.serialization.json.internal.JsonDecodingException: Polymorphic serializer was not found for missing class discriminator ('null') JSON input: {"success":true,"message":"Otp sent successfully","data":{"countryCode":"880","mobileNo":" 99999999","type":"New","testOtp":63401}}

how can i fix it?

@JobGetabu
Copy link

try @keep
for all models

@saurabhnmahajan
Copy link

If you're using a Call like fun fetchSomething(): Call<Something>, make sure it's not a suspend function

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