package com.aiosman.riderpro

import android.content.Context

object ConstVars {
    // api 地址
//    const val BASE_SERVER = "http://192.168.31.190:8088"        const val BASE_SERVER = "https://8.137.22.101:8088"
    const val BASE_SERVER = "https://8.137.22.101:8088"

    const val MOMENT_LIKE_CHANNEL_ID = "moment_like"
    const val MOMENT_LIKE_CHANNEL_NAME = "Moment Like"

}

enum class ErrorCode(val code: Int) {
    USER_EXIST(10001)
}

fun Context.getErrorMessageCode(code: Int?): String {
    return when (code) {
        10001 -> getString(R.string.error_10001_user_exist)
        else -> getString(R.string.error_unknown)
    }
}