diff options
author | Keuin <[email protected]> | 2023-01-13 02:49:57 +0800 |
---|---|---|
committer | Keuin <[email protected]> | 2023-01-13 02:49:57 +0800 |
commit | 5dc6e700cbcbc01833a02a193f660a286b934898 (patch) | |
tree | 72cf4cc3cfae2b3a7fb978bc0c465e329909db3e /src/main/java/com/keuin/kbackupfabric/operation | |
parent | ff7d23b5b915f04c2b5f3614701cb56cfc605228 (diff) |
Code cleanup.
Diffstat (limited to 'src/main/java/com/keuin/kbackupfabric/operation')
4 files changed, 4 insertions, 5 deletions
diff --git a/src/main/java/com/keuin/kbackupfabric/operation/BackupOperation.java b/src/main/java/com/keuin/kbackupfabric/operation/BackupOperation.java index 1798fb7..3fec8b9 100644 --- a/src/main/java/com/keuin/kbackupfabric/operation/BackupOperation.java +++ b/src/main/java/com/keuin/kbackupfabric/operation/BackupOperation.java @@ -33,7 +33,7 @@ public class BackupOperation extends InvokableAsyncBlockingOperation { protected void async() { String backupSaveDirectory = ""; MinecraftServer server = context.getSource().getMinecraftServer(); - boolean success = false; // only success when everything is done + boolean success; // only success when everything is done try { //// Do our main backup logic diff --git a/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractAsyncOperation.java b/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractAsyncOperation.java index bb0c704..2dac710 100644 --- a/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractAsyncOperation.java +++ b/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractAsyncOperation.java @@ -2,7 +2,7 @@ package com.keuin.kbackupfabric.operation.abstracts; /** * A basic async operation, but not invokable. - * If you want a invokable interface (InvokableOperation), use InvokableAsyncOperation instead. + * If you want an invokable interface (InvokableOperation), use InvokableAsyncOperation instead. */ public abstract class AbstractAsyncOperation extends AbstractSerialOperation { diff --git a/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractSerialOperation.java b/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractSerialOperation.java index 92dfb53..db5433f 100644 --- a/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractSerialOperation.java +++ b/src/main/java/com/keuin/kbackupfabric/operation/abstracts/AbstractSerialOperation.java @@ -2,7 +2,7 @@ package com.keuin.kbackupfabric.operation.abstracts; /** * The most basic operation abstraction. - * This class represents an serial operation, which is limited in a non-public method. + * This class represents a serial operation, which is limited in a non-public method. * Note that the operation is not invokable by default, you should use InvokableOperation in order to provide a public method for users to call. */ public abstract class AbstractSerialOperation { diff --git a/src/main/java/com/keuin/kbackupfabric/operation/backup/method/ConfiguredIncrementalBackupMethod.java b/src/main/java/com/keuin/kbackupfabric/operation/backup/method/ConfiguredIncrementalBackupMethod.java index 2cc0765..cfc9b81 100644 --- a/src/main/java/com/keuin/kbackupfabric/operation/backup/method/ConfiguredIncrementalBackupMethod.java +++ b/src/main/java/com/keuin/kbackupfabric/operation/backup/method/ConfiguredIncrementalBackupMethod.java @@ -99,7 +99,6 @@ public class ConfiguredIncrementalBackupMethod implements ConfiguredBackupMethod PrintUtil.info("Incremental backup finished."); feedback = new IncrementalBackupFeedback(true, copyResult); } catch (IOException e) { -// e.printStackTrace(); // stack trace has been passed to backup feedback. No need to print here. feedback = new IncrementalBackupFeedback(e); } @@ -119,7 +118,7 @@ public class ConfiguredIncrementalBackupMethod implements ConfiguredBackupMethod // remove unused object files in the base if (collection != null) { try { - // collection may have been copied (partially) to the base, but we may not need them + // collection may have been copied (partially) to the base, but we may not need them, // so we perform a clean here // perform a clean-up Iterable<ObjectCollection2> backups = ObjectCollectionSerializer.fromDirectory(new File(backupIndexFileSaveDirectory)); |