Skip to content

Commit

Permalink
vote-validator: Use stdlib built-in "POST" const.
Browse files Browse the repository at this point in the history
  • Loading branch information
jholdstock committed Jun 28, 2024
1 parent cab4058 commit 11cddac
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/vote-validator/dcrdata.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2021-2023 The Decred developers
// Copyright (c) 2021-2024 The Decred developers
// Use of this source code is governed by an ISC
// license that can be found in the LICENSE file.

Expand Down Expand Up @@ -56,7 +56,7 @@ func (d *dcrdataClient) txns(ctx context.Context, txnHashes []string, spends boo
}

url := fmt.Sprintf("%s/api/txs?spends=%t", d.URL, spends)
request, err := http.NewRequestWithContext(ctx, "POST", url, bytes.NewBuffer(jsonData))
request, err := http.NewRequestWithContext(ctx, http.MethodPost, url, bytes.NewBuffer(jsonData))
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 11cddac

Please sign in to comment.