|
|
@@ -1,6 +1,7 @@
|
|
|
package com.yingyang.personalcenter.personalcenter
|
|
|
|
|
|
import android.annotation.SuppressLint
|
|
|
+import android.text.TextUtils
|
|
|
import android.view.MotionEvent
|
|
|
import android.view.View
|
|
|
import com.alibaba.android.arouter.facade.annotation.Route
|
|
|
@@ -70,16 +71,17 @@ class PersonalCenterActivity :
|
|
|
if (it != null) {
|
|
|
binding.data = it
|
|
|
//保存用户头像
|
|
|
- if (it.avatar.isEmpty().not()) {
|
|
|
+ //保存用户头像
|
|
|
+ if (TextUtils.isEmpty(it.avatar).not()) {
|
|
|
User.saveAvatar(it.avatar)
|
|
|
}
|
|
|
//保存用户名
|
|
|
- if (it.name.isEmpty().not()) {
|
|
|
+ if (TextUtils.isEmpty(it.name).not()) {
|
|
|
User.saveName(it.name)
|
|
|
}
|
|
|
User.saveUserSex(it.getSex())
|
|
|
User.saveUserAge(it.getAgeInfo())
|
|
|
- if (it.id.isEmpty().not()) {
|
|
|
+ if (TextUtils.isEmpty(it.id).not()) {
|
|
|
User.saveUserId(it.id)
|
|
|
}
|
|
|
if (it.diagnoseResult.isNullOrEmpty().not()) {
|