Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 1cfcaad

Browse files
Merge pull request #983 from github-for-unity/copyhelper-fixes
Fixing the logging of CopyHelper
2 parents 9ada287 + 239d643 commit 1cfcaad

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/GitHub.Api/Installer/CopyHelper.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ public static class CopyHelper
1212

1313
public static void Copy(NPath fromPath, NPath toPath)
1414
{
15-
Logger.Trace("Copying from " + fromPath + " to " + toPath + ".");
15+
Logger.Trace("Copying from {0} to {1}", fromPath, toPath);
1616

1717
try
1818
{
@@ -28,7 +28,7 @@ public static void Copy(NPath fromPath, NPath toPath)
2828
}
2929
catch (Exception ex2)
3030
{
31-
Logger.Error(ex1, "Error copying contents.");
31+
Logger.Error(ex2, "Error copying contents.");
3232
throw;
3333
}
3434
}
@@ -39,15 +39,15 @@ public static void Copy(NPath fromPath, NPath toPath)
3939
}
4040
public static void CopyFolder(NPath fromPath, NPath toPath)
4141
{
42-
Logger.Trace("CopyFolder fromPath: {0} toPath:{1}", fromPath.ToString(), toPath.ToString());
42+
Logger.Trace("CopyFolder from {0} to {1}", fromPath, toPath);
4343
toPath.DeleteIfExists();
4444
toPath.EnsureParentDirectoryExists();
4545
fromPath.Move(toPath);
4646
}
4747

4848
public static void CopyFolderContents(NPath fromPath, NPath toPath)
4949
{
50-
Logger.Trace("CopyFolder Contents fromPath: {0} toPath:{1}", fromPath.ToString(), toPath.ToString());
50+
Logger.Trace("CopyFolderContents from {0} to {1}", fromPath, toPath);
5151
toPath.DeleteContents();
5252
fromPath.MoveFiles(toPath, true);
5353
}

0 commit comments

Comments
 (0)