package com.gh.gamecenter.livedata

import androidx.lifecycle.Observer

class EventObserver<T>(private val eventInvoke: (T) -> Unit) : Observer<Event<T>> {
    override fun onChanged(t: Event<T>) {
        t.getContentWithHandled()?.let(eventInvoke)
    }
}