From ca4c0538635a2f6a3894325e3bc7a3dfbb6b5ee3 Mon Sep 17 00:00:00 2001 From: shugomatsuzawa <50859459+shugomatsuzawa@users.noreply.github.com> Date: Thu, 15 Aug 2024 16:27:51 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=87=E3=83=BC=E3=82=BF=E3=82=A4=E3=83=B3?= =?UTF-8?q?=E3=83=9D=E3=83=BC=E3=83=88=E3=81=AE=E4=B8=8D=E5=85=B7=E5=90=88?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.json | 2 +- screens/data/DataScreen.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app.json b/app.json index 0768f98..ab0c511 100644 --- a/app.json +++ b/app.json @@ -15,7 +15,7 @@ "ios": { "supportsTablet": true, "bundleIdentifier": "com.shugomatsuzawa", - "buildNumber": "1.1.004", + "buildNumber": "1.1.005", "requireFullScreen": true, "splash": { "image": "./assets/splash.png", diff --git a/screens/data/DataScreen.js b/screens/data/DataScreen.js index 50bbea1..4f2abb1 100644 --- a/screens/data/DataScreen.js +++ b/screens/data/DataScreen.js @@ -108,9 +108,9 @@ const DataScreen = ({ navigation }) => { } const importFile = async () => { - const { type, uri } = await DocumentPicker.getDocumentAsync({type: 'application/json'}); - if (type === 'success') { - const fileUri = uri; + const { assets, canceled } = await DocumentPicker.getDocumentAsync({multiple: false, type: 'application/json'}); + if (canceled === false) { + const fileUri = assets[0].uri; console.debug(fileUri); const txtFileRaw = await FileSystem.readAsStringAsync(fileUri); try{