The !! Operator
Force non-null and its risks.
Forcing Non-Null
Sometimes you are certain a nullable value is not null, but the compiler still complains.
The not-null assertion operator !! tells the compiler to trust you and treat the value as non-null.
Basic Usage
Adding !! converts a nullable type to its non-null counterpart.
If the value really is non-null, the code works exactly like a normal call.
fun main() {
val name: String? = "Kotlin"
println(name!!.length)
}