Merge pull request #3908 from buthed010203/patch-2

Delete old bleeding edge builds on update
This commit is contained in:
Anuken 2020-12-11 10:52:19 -05:00 committed by GitHub
commit c444cbf623
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -49,6 +49,8 @@ public class BeControl{
try{
Fi dest = Fi.get(System.getProperty("becopy"));
Fi self = Fi.get(BeControl.class.getProtectionDomain().getCodeSource().getLocation().toURI().getPath());
for(Fi file : self.parent().findAll(f -> !f.equals(self))) file.delete();
self.copyTo(dest);
}catch(Throwable e){