Skip to content

Commit

Permalink
Fix(command cp'): download single file of recursive mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
LemonPrefect committed Dec 12, 2022
1 parent 79acb12 commit 3e5e927
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions commands/cp/download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export default async function download(config: Config, paths: Array<string>, opt
}

let tasks: Array<IFile> = [] as Array<IFile>;
if(originalFileCount === 1){
if(originalFileCount === 1 && !dogePath.endsWith("/")){
files[0].local = fullpath;
tasks.push(files[0]);
}else{
Expand All @@ -69,7 +69,6 @@ export default async function download(config: Config, paths: Array<string>, opt
if(options.signUrl){
console.log(warn("[WARN]"), "This url is CHARGED for CNY0.5/GB/DAY");
}

for(const task of tasks){
let size;
try{
Expand Down

0 comments on commit 3e5e927

Please sign in to comment.