Skip to content

Commit

Permalink
hotfix: don't set repo flag if not specified
Browse files Browse the repository at this point in the history
Signed-off-by: moson-mo <mo-son@mailbox.org>
  • Loading branch information
moson-mo committed Oct 21, 2022
1 parent eb091dd commit 644813a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion internal/args/args.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,17 @@ func Parse() Flags {
}

flags := Flags{
Repositories: strings.Split(*repos, ","),
SearchTerm: *term,
AsciiMode: *ascii,
MonochromeMode: *mono,
ShowUpdates: *upd,
ShowInstalled: *inst,
}

if len(*repos) > 0 {
flags.Repositories = strings.Split(*repos, ",")
}

flags.Help = *help || *qhelp

if flags.SearchTerm == "" && len(getopt.Args()) > 0 {
Expand Down

0 comments on commit 644813a

Please sign in to comment.