Ver código fonte

Merge branch 'master' of http://git.ycjcjy.com/nanyang/machinery-miniapp

[baozhangchao] 3 anos atrás
pai
commit
4b8d55a255
1 arquivos alterados com 3 adições e 1 exclusões
  1. 3
    1
      src/pages/index/tabs/Mine.jsx

+ 3
- 1
src/pages/index/tabs/Mine.jsx Ver arquivo

@@ -40,7 +40,9 @@ export default withLayout((props) => {
40 40
   useDidShow(() => {
41 41
     getAddress().then((e) => {
42 42
       let abccList = e.records.sort((a, b) => b.isDefault - a.isDefault)
43
-      setAddresInfo(abccList[0].address)
43
+      if (abccList.length!=0) {        
44
+        setAddresInfo(abccList[0].address)
45
+      }
44 46
     })
45 47
     if ($instance.router.params.userOk || person.phone) {
46 48
       setIsLoginBox(true)