Browse Source

minor bug fix of 'null' and 'undefined'

Nivek 2 years ago
parent
commit
9903016a35
1 changed files with 3 additions and 3 deletions
  1. 3 3
      src/views/user/Dashboard.vue

+ 3 - 3
src/views/user/Dashboard.vue

@@ -42,7 +42,7 @@ function getUserInfo() {
 function updateInfo() {
 function updateInfo() {
   userInfoUpdate({
   userInfoUpdate({
     name: newName.value,
     name: newName.value,
-    password: null,
+    password: undefined,
     address: address.value,
     address: address.value,
   }).then(res => {
   }).then(res => {
     if (res.data.code === '000') {
     if (res.data.code === '000') {
@@ -64,9 +64,9 @@ function updateInfo() {
 
 
 function updatePassword() {
 function updatePassword() {
   userInfoUpdate({
   userInfoUpdate({
-    name: null,
+    name: undefined,
     password: password.value,
     password: password.value,
-    address: null
+    address: undefined
   }).then(res => {
   }).then(res => {
     if (res.data.code === '000') {
     if (res.data.code === '000') {
       password.value = ''
       password.value = ''