package com.zaojiao.app.data.remote

import com.zaojiao.app.core.common.state.DataState
import com.zaojiao.app.core.http.common.dataStateCatch
import com.zaojiao.app.data.model.UserGetV2Model
import com.zaojiao.app.data.model.interactive.InteractiveCountModel
import com.zaojiao.app.data.model.user.UserModel
import com.zaojiao.app.data.remote.api.UserApi
import javax.inject.Inject
import javax.inject.Singleton

@Singleton
class RemoteUserData @Inject constructor(
    private val userApi: UserApi,
) {
    suspend fun getUserInfo(): DataState<UserModel> {
        return dataStateCatch { userApi.getUserInfo() }
    }

    suspend fun getUserInactive(): DataState<InteractiveCountModel> {
        return dataStateCatch { userApi.getUserInactive() }
    }
}