修改文件删除中多余代码
This commit is contained in:
parent
b616a2f2e7
commit
3329e733f3
@ -86,15 +86,13 @@ public class FileUtils
|
||||
*/
|
||||
public static boolean deleteFile(String filePath)
|
||||
{
|
||||
boolean flag = false;
|
||||
File file = new File(filePath);
|
||||
// 路径为文件且不为空则进行删除
|
||||
if (file.isFile() && file.exists())
|
||||
{
|
||||
file.delete();
|
||||
flag = true;
|
||||
return file.delete();
|
||||
}
|
||||
return flag;
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user