You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried upgrading to 1.2.1, but got Type mismatch: inferred type is List<Serializable> but List<String> was expected on some existing code. I tried every older version until I found the change happened in 1.1.4. This is the code in question:
It says the function getContactPoints returns List<Serializable>, which I cannot understand. ContactPoint::contact returns a string. Map returns a bog standard kotlin.collections List. If I remove the getOrElse I see that the object is Either<Throwable, List<String>>, which is perfect. Somehow getOrElse changes String to Serializable. In the end I just slapped a as List<String> on it, but not sure why this is happening
I am not sure what happened in 1.1.4, as I could not see anything obvious in the changelog.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I tried upgrading to 1.2.1, but got
Type mismatch: inferred type is List<Serializable> but List<String> was expected
on some existing code. I tried every older version until I found the change happened in 1.1.4. This is the code in question:It says the function
getContactPoints
returnsList<Serializable>
, which I cannot understand.ContactPoint::contact
returns a string. Map returns a bog standard kotlin.collections List. If I remove thegetOrElse
I see that the object isEither<Throwable, List<String>>
, which is perfect. SomehowgetOrElse
changes String to Serializable. In the end I just slapped aas List<String>
on it, but not sure why this is happeningI am not sure what happened in 1.1.4, as I could not see anything obvious in the changelog.
Beta Was this translation helpful? Give feedback.
All reactions