Skip to content

Commit

Permalink
fix: issue with '--archive' default
Browse files Browse the repository at this point in the history
  • Loading branch information
lightpohl committed Aug 13, 2021
1 parent d40dd8c commit 551c0a8
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions bin/bin.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,8 @@ commander
.option("--url <string>", "url to podcast rss feed")
.option("--out-dir <path>", "specify output directory", "./{{podcast_title}}")
.option(
"--archive <path>",
"download or write only items not listed in archive file",
"./{{podcast_title}}/archive.json"
"--archive [path]",
"download or write only items not listed in archive file"
)
.option(
"--episode-template <string>",
Expand Down Expand Up @@ -191,6 +190,10 @@ const main = async () => {
}

if (archive) {
archive =
typeof archive === "boolean"
? "./{{podcast_title}}/archive.json"
: archive;
archive = getFolderName({ feed, template: archive });
}

Expand Down

0 comments on commit 551c0a8

Please sign in to comment.