Now that is a really crappy API in Android that returns an array with null values.

closes #167
here
cpfeiffer 2015-11-18 23:17:28 +01:00
parent ea98e207d9
commit 1e6db708d2
1 changed files with 1 additions and 1 deletions

View File

@ -97,7 +97,7 @@ public class FileUtils {
}
for (int i = 0; i < dirs.length; i++) {
File dir = dirs[i];
if (!dir.exists() && !dir.mkdirs()) {
if (dir == null || (!dir.exists() && !dir.mkdirs())) {
continue;
}
// the first directory is also the primary external storage, i.e. the same as Environment.getExternalFilesDir()