pull/362/head
FongMi 2 years ago
parent 7b91fe1315
commit b1f95ac460
  1. 11
      catvod/src/main/java/com/github/catvod/utils/Path.java

@ -194,17 +194,8 @@ public class Path {
public static File create(File file) throws Exception { public static File create(File file) throws Exception {
try { try {
if (!file.exists()) file.createNewFile();
if (!file.canWrite()) file.setWritable(true); if (!file.canWrite()) file.setWritable(true);
return chmod(file); if (!file.exists()) file.createNewFile();
} catch (Exception e) {
e.printStackTrace();
return file;
}
}
public static File chmod(File file) {
try {
Shell.exec("chmod 777 " + file); Shell.exec("chmod 777 " + file);
return file; return file;
} catch (Exception e) { } catch (Exception e) {

Loading…
Cancel
Save