I get 2 data class responses, one at a time, from the network call. I used a sealed class for that but got a response error on the sealed class mentioning, "Failed to invoke private [packagename].LiveExamResponse() with no args"
on logcat I'm getting the correct response from the API call, just not being able to map it to the sealed class.
sealed class LiveExamResponse {
data class LiveExamQuestion(val response: LiveExamQuestionResponse) : LiveExamResponse()
data class Other(val response: OtherResponse) : LiveExamResponse()
constructor() // public constructor without arguments
}