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

Commit

Permalink
Merge branch 'copyhelper-fixes' into releases/v1.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
StanleyGoldman committed Oct 23, 2018
2 parents c215aee + 26a9d0a commit c99b7b5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/GitHub.Api/Installer/CopyHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public static class CopyHelper

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

try
{
Expand All @@ -28,7 +28,7 @@ public static void Copy(NPath fromPath, NPath toPath)
}
catch (Exception ex2)
{
Logger.Error(ex1, "Error copying contents.");
Logger.Error(ex2, "Error copying contents.");
throw;
}
}
Expand All @@ -39,15 +39,15 @@ public static void Copy(NPath fromPath, NPath toPath)
}
public static void CopyFolder(NPath fromPath, NPath toPath)
{
Logger.Trace("CopyFolder fromPath: {0} toPath:{1}", fromPath.ToString(), toPath.ToString());
Logger.Trace("CopyFolder from {0} to {1}", fromPath, toPath);
toPath.DeleteIfExists();
toPath.EnsureParentDirectoryExists();
fromPath.Move(toPath);
}

public static void CopyFolderContents(NPath fromPath, NPath toPath)
{
Logger.Trace("CopyFolder Contents fromPath: {0} toPath:{1}", fromPath.ToString(), toPath.ToString());
Logger.Trace("CopyFolder Contents from {0} to {1}", fromPath, toPath);
toPath.DeleteContents();
fromPath.MoveFiles(toPath, true);
}
Expand Down

0 comments on commit c99b7b5

Please sign in to comment.