I’m trying to pass a value into a callback functio...
# android
c
I’m trying to pass a value into a callback function that runs an API request and passes the value to filter out the result on the backend. Unfortunately there seems to be type mismatches that I’m not sure how to rectify. By declaring
marketingType
as
String
, I get a type error where the API request expects a type of
MarketingType
on the
marketingType
key in the request. However, by changing
marketingType
to
MarketingType
(Which is just an enum that returns possible strings) in
FeaturedState
data class, when I attempt to change the type in
changeMarketing
function, I get type issues as well. Not sure where to change what. FeaturedState and `changeMarketing()`: https://hatebin.com/vcuswntlkf API Request and callback: https://hatebin.com/arrrcsnisn Custom enum type for marketing: https://hatebin.com/wzjoafflfd