From f403b7786445adfa176cad95c1e8489386b343af Mon Sep 17 00:00:00 2001 From: ProfessionalUwU Date: Thu, 29 Jun 2023 02:03:41 +0200 Subject: [PATCH] Code cleanup --- src/Chksum/chksum.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Chksum/chksum.cs b/src/Chksum/chksum.cs index ca6e32a..40a0694 100644 --- a/src/Chksum/chksum.cs +++ b/src/Chksum/chksum.cs @@ -181,7 +181,7 @@ public class ChksumUtils { command2.Parameters.AddWithValue("$filehash", fileHash); command2.ExecuteNonQuery(); - Console.WriteLine("File moved:"); + Console.WriteLine("File moved or is a duplicate:"); Console.WriteLine($"\tfrom\t{pathToFile}"); Console.WriteLine($"\tto \t{pathtofile}\n"); wasMoved = true; @@ -252,7 +252,6 @@ public class ChksumUtils { public void compareDatabases(string filePathToOtherDatabase) { List filesThatDoNotExistsInTheRemote = getFilehashesFromDatabase("Data Source=" + DatabaseRoot + "chksum.db;Mode=ReadOnly").Except(getFilehashesFromDatabase("Data Source=" + filePathToOtherDatabase + ";Mode=ReadOnly")).ToList(); - //List filesThatDoNotExistsInTheOrigin = filehashesOfRemoteDatabase.Except(filehashesOfOriginDatabase).ToList(); foreach (string file in filesThatDoNotExistsInTheRemote) { using (var connection = new SqliteConnection("Data Source=" + DatabaseRoot + "chksum.db;Mode=ReadOnly")) {