diff options
author | Keuin <[email protected]> | 2021-01-14 13:00:52 +0800 |
---|---|---|
committer | keuin <[email protected]> | 2021-01-14 13:00:52 +0800 |
commit | 6baece29cccc906651331cbf8a90a06f8cee045b (patch) | |
tree | 37a33912b7b057376a4c2845738f076ac7da3467 /src/main/java/com/keuin/kbackupfabric/KBCommands.java | |
parent | 5410762b8272feca0680f7a48f895714b91e3df7 (diff) |
Fix a minor naming bug.
Code refactor.
Improve test.
Diffstat (limited to 'src/main/java/com/keuin/kbackupfabric/KBCommands.java')
-rw-r--r-- | src/main/java/com/keuin/kbackupfabric/KBCommands.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/com/keuin/kbackupfabric/KBCommands.java b/src/main/java/com/keuin/kbackupfabric/KBCommands.java index 847fe7c..98f6369 100644 --- a/src/main/java/com/keuin/kbackupfabric/KBCommands.java +++ b/src/main/java/com/keuin/kbackupfabric/KBCommands.java @@ -84,7 +84,9 @@ public final class KBCommands { public static int list(CommandContext<ServerCommandSource> context) { MinecraftServer server = context.getSource().getMinecraftServer(); File[] files = getBackupSaveDirectory(server).listFiles( - (dir, name) -> dir.isDirectory() && name.toLowerCase().endsWith(".zip") && name.toLowerCase().startsWith(getBackupFileNamePrefix()) + (dir, name) -> dir.isDirectory() && + (name.toLowerCase().endsWith(".zip") && name.toLowerCase().startsWith(getBackupFileNamePrefix()) + || name.toLowerCase().endsWith(".kbi")) ); synchronized (backupFileNameList) { |