https://kotlinlang.org logo
m

Michael Limb

03/19/2020, 7:47 PM
why am i getting this when the var is internal?
s

Shawn

03/19/2020, 7:51 PM
the constructor is still public though
exposing the reliance on an internal type
m

Michael Limb

03/19/2020, 7:51 PM
oh okay, so i need to make the constructor internal
and have a secondary public constructor
s

Shawn

03/19/2020, 7:52 PM
that’d be one way to do it, yes 👍
m

Michael Limb

03/19/2020, 7:52 PM
thank you!
z

Zach Klippenstein (he/him) [MOD]

03/19/2020, 8:10 PM
Although even then, because this is a data class, this type will still be exposed in the
copy
method. You sure it needs to be a data class?
👆 1
m

Michael Limb

03/19/2020, 8:11 PM
i'll need to look into it