更新代码

This commit is contained in:
2024-11-03 09:18:28 +08:00
parent 3cef90c887
commit d5e210b080

View File

@@ -34,16 +34,4 @@ object ConstVars {
// 重置邮箱间隔 // 重置邮箱间隔
const val DIC_KEY_RESET_EMAIL_INTERVAL = "send_reset_password_timeout" const val DIC_KEY_RESET_EMAIL_INTERVAL = "send_reset_password_timeout"
} }
//
enum class ErrorCode(val code: Int) {
USER_EXIST(40001),
USER_NOT_EXIST(40002),
InvalidateCaptcha(40004),
}
fun Context.getErrorMessageCode(code: Int?): String {
return when (code) {
10001 -> getString(R.string.error_10001_user_exist)
else -> getString(R.string.error_unknown)
}
}