Ensure modification date greater than creation

This commit is contained in:
Jesse Boyd 2017-04-15 10:21:32 +10:00
parent 39f848cccc
commit b9854d31e3
No known key found for this signature in database
GPG Key ID: 59F1DE6293AF6E1F

View File

@ -118,7 +118,7 @@ public class AnvilCommands {
BasicFileAttributes attr = Files.readAttributes(file.toPath(), BasicFileAttributes.class);
long creation = attr.creationTime().toMillis();
long modified = attr.lastModifiedTime().toMillis();
if (modified - creation < fileAgeMillis) {
if (modified - creation < fileAgeMillis && modified > creation) {
mca.setDeleted(true);
get().add(512 * 512 * 256);
return null;