mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2025-12-19 15:09:18 +00:00
remove old worlds from cache before retrieving
This commit is contained in:
@@ -66,6 +66,7 @@ public class IrisWorlds {
|
||||
}
|
||||
|
||||
public KMap<String, String> getWorlds() {
|
||||
clean();
|
||||
return readBukkitWorlds().put(worlds);
|
||||
}
|
||||
|
||||
@@ -76,8 +77,7 @@ public class IrisWorlds {
|
||||
}
|
||||
|
||||
public Stream<IrisDimension> getDimensions() {
|
||||
return readBukkitWorlds()
|
||||
.put(worlds)
|
||||
return getWorlds()
|
||||
.entrySet()
|
||||
.stream()
|
||||
.map(entry -> Iris.loadDimension(entry.getKey(), entry.getValue()))
|
||||
|
||||
@@ -1705,6 +1705,7 @@ public class IO {
|
||||
action.accept(out);
|
||||
}
|
||||
Files.copy(temp.toPath(), Channels.newOutputStream(target));
|
||||
target.truncate(temp.length());
|
||||
} finally {
|
||||
temp.delete();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user