张延森 il y a 3 ans
Parent
révision
6a62c3f337
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1
    1
      src/components/barcode/CodeText.jsx

+ 1
- 1
src/components/barcode/CodeText.jsx Voir le fichier

@@ -8,7 +8,7 @@ export default (props) => {
8 8
   return (
9 9
     <View className='barcode-txt'>
10 10
       {
11
-        code.split('').map(it => (<View key={it}>{it}</View>))
11
+        code && code.split('').map(it => (<View key={it}>{it}</View>))
12 12
       }
13 13
     </View>
14 14
   )