Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

Commit

Permalink
fix: don't delete the parent directory of the task file
Browse files Browse the repository at this point in the history
Signed-off-by: lowzj <[email protected]>
  • Loading branch information
lowzj committed May 22, 2020
1 parent 386e25f commit b23342a
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions supernode/daemon/mgr/cdn/path_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,13 +69,6 @@ func getMd5DataRaw(taskID string) *store.Raw {
}
}

func getParentRaw(taskID string) *store.Raw {
return &store.Raw{
Bucket: config.DownloadHome,
Key: getParentKey(taskID),
}
}

func getHomeRaw() *store.Raw {
return &store.Raw{
Bucket: config.DownloadHome,
Expand All @@ -98,10 +91,5 @@ func deleteTaskFiles(ctx context.Context, cacheStore *store.Store, taskID string
return err
}

if err := cacheStore.Remove(ctx, getParentRaw(taskID)); err != nil &&
!store.IsKeyNotFound(err) {
return err
}

return nil
}

0 comments on commit b23342a

Please sign in to comment.