onSuccess

inline fun <T> ChannelResult<T>.onSuccess(action: (T) -> Unit): ChannelResult<T>

Performs the given action on the encapsulated value if this instance represents success. Returns the original ChannelResult unchanged.

Sources

Link copied to clipboard