android-components / mozilla.components.service.fxa / FxaResult / whenComplete

whenComplete

fun whenComplete(fn: (value: T) -> Unit): Unit (source)

Adds a value listener to be called when the FxaResult and the whole chain of then calls is completed with a value. Listeners will be invoked on the same thread in which the FxaResult was completed.

Parameters

fn - A lambda expression with the same method signature as OnValueListener, called when the FxaResult is completed with a value.