ソースを参照

Merge pull request #69 from shahen94/master

fix(RNViewShotModule): FileNotFound exception
Gaëtan Renaudeau 7 年 前
コミット
c421819913
共有1 個のファイルを変更した1 個の追加1 個の削除を含む
  1. 1
    1
      android/src/main/java/fr/greweb/reactnativeviewshot/RNViewShotModule.java

+ 1
- 1
android/src/main/java/fr/greweb/reactnativeviewshot/RNViewShotModule.java ファイルの表示

@@ -78,7 +78,7 @@ public class RNViewShotModule extends ReactContextBaseJavaModule {
78 78
             if ("file".equals(result)) {
79 79
                 if (options.hasKey("path")) {
80 80
                     file = new File(options.getString("path"));
81
-                    file.mkdirs();
81
+                    file.getParentFile().mkdirs();
82 82
                     file.createNewFile();
83 83
                 }
84 84
                 else {