Ah yes thanks. Now it works. Was too focussed on after the null check.
g
gildor
04/10/2018, 7:29 AM
Just realised that this is off-topic for this chanenl
j
Jurriaan Mous
04/10/2018, 7:31 AM
I guessed this warning had to do with the kotlin plugin in Intellij since the compiler was saying that I had to smart cast. So intellij plugin and compiler were pointing in opposite directions. Or is this assumption wrong?
g
gildor
04/10/2018, 7:35 AM
No, this is not related to IDE plugin, this is Kotlin compiler feature
gildor
04/10/2018, 7:36 AM
but probably you right and Intellij could give you additional advice how to fix it. But in general this is correct warning, you cannot use variable of incompatible type