Hi! I have strange problem with Kotlin 1.3.40. Can...
# getting-started
n
Hi! I have strange problem with Kotlin 1.3.40. Can anybody explain this?
a
Could you share the whole line with
localized
?
a
It seems that localized returns a non nullable object
Thus message would "never" be null
So if you check for null the compiler is generating a warning that the check is unnecessary
But it seems that you have set the compiler to report warnings as errors
So the build fails
n
Copy code
Could you share the whole line with `localized`?
Copy code
val message = context.localized(CLICK_WITHIN_LIVECHAT_MESSAGE)
localized last function 😞
Copy code
It seems that localized returns a non nullable object
It returns “String?“. I showed hint from intelliJ on screenshot.
And it seems strange to me 😞
a
Hmm.. I did not pay attention to that.
Sorry for stating the obvious 🤦‍♂️ 😄
a
This looks like a bug. Could you please report an issue at http://kotl.in/issue with some sample code to reproduce?