Skip to content
This repository has been archived by the owner on Jul 30, 2020. It is now read-only.

Commit

Permalink
Merge branch 'master' of github.com:merklecounty/rget
Browse files Browse the repository at this point in the history
  • Loading branch information
Brandon Philips committed Jul 29, 2019
2 parents 60f3f83 + 0be33b6 commit 152ec04
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion rget/cmd/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,10 @@ func (r sumRepo) handler(resp http.ResponseWriter, req *http.Request) {
}

func server(cmd *cobra.Command, args []string) {
if len(args) < 2 {
fmt.Printf("missing required arguments (public git URL, private git URL)\n")
os.Exit(1)
}
pubgit := args[0]
privgit := args[1]

Expand Down Expand Up @@ -161,7 +165,7 @@ func server(cmd *cobra.Command, args []string) {
}

if !strings.HasSuffix(host, "."+rgetwellknown.PublicServiceHost) {
return nil, errors.New(fmt.Sprintf("not in TLD %v", rgetwellknown.PublicServiceHost))
return nil, fmt.Errorf("not in TLD %v", rgetwellknown.PublicServiceHost)
}

key := strings.TrimSuffix(host, "."+rgetwellknown.PublicServiceHost)
Expand Down

0 comments on commit 152ec04

Please sign in to comment.