Panggilan balik opsional Kotlin

fun method(callback: () -> Unit = {}) {
  // Do stuff...

  callback()
}
davwheat