Skip to content

Commit

Permalink
fix: make file names safe in groups
Browse files Browse the repository at this point in the history
  • Loading branch information
anna-is-cute committed Aug 24, 2024
1 parent 7f7442b commit 973292e
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions DownloadTask.cs
Original file line number Diff line number Diff line change
Expand Up @@ -810,11 +810,6 @@ private void RemoveOldFiles() {
this.State = State.RemovingOldFiles;
this.SetStateData(0, 0);

Plugin.Log.Info("expected files:");
foreach (var exp in this.ExpectedFiles) {
Plugin.Log.Info($" {exp}");
}

// find old, normal files no longer being used to remove
var filesPath = Path.Join(this.PenumbraModPath, "files");

Expand All @@ -825,11 +820,6 @@ private void RemoveOldFiles() {
.Select(path => path.ToLowerInvariant())
.ToHashSet();

Plugin.Log.Info("present files:");
foreach (var exp in presentFiles) {
Plugin.Log.Info($" {exp}");
}

// remove the files that we expect from the list of already-existing
// files - these are the files to remove now
presentFiles.ExceptWith(this.ExpectedFiles);
Expand Down Expand Up @@ -1022,8 +1012,8 @@ private static string GetReplacedPath(List<string?> file) {

var replacedPath = outputPath == null
? Path.Join(
file[0] ?? DefaultFolder,
file[1] ?? DefaultFolder,
MakeFileNameSafe(file[0] ?? DefaultFolder),
MakeFileNameSafe(file[1] ?? DefaultFolder),
MakePathPartsSafe(gamePath)
)
: MakePathPartsSafe(outputPath);
Expand Down

0 comments on commit 973292e

Please sign in to comment.