mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-13 11:19:04 +01:00
Don't infer anything from existence of (possibly empty) DB directory.
This commit is contained in:
@@ -117,4 +117,10 @@ public class IoUtils {
|
||||
throw new IOException(e);
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean isNonEmptyDirectory(File f) {
|
||||
if (!f.isDirectory()) return false;
|
||||
File[] children = f.listFiles();
|
||||
return children != null && children.length > 0;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user