Skip to content

Commit a594f05

Browse files
committed
multi: fix linter issues
1 parent 1474313 commit a594f05

File tree

6 files changed

+11
-7
lines changed

6 files changed

+11
-7
lines changed

.golangci.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,10 @@ linters:
5353
- scopelint
5454
- golint
5555
- exhaustivestruct
56+
- nosnakecase
57+
- deadcode
58+
- structcheck
59+
- varcheck
5660

5761
issues:
5862
exclude-rules:

btc/bip39.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ func ReadMnemonicFromTerminal(params *chaincfg.Params) (*hdkeychain.ExtendedKey,
8383
fmt.Printf("Input your cipher seed passphrase (press enter " +
8484
"if your seed doesn't have a passphrase): ")
8585
passphraseBytes, err = terminal.ReadPassword(
86-
int(syscall.Stdin), // nolint
86+
int(syscall.Stdin), //nolint
8787
)
8888
if err != nil {
8989
return nil, err

cmd/chantools/root.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,9 +240,9 @@ func readInput(input string) ([]byte, error) {
240240

241241
func passwordFromConsole(userQuery string) ([]byte, error) {
242242
// Read from terminal (if there is one).
243-
if terminal.IsTerminal(int(syscall.Stdin)) { // nolint
243+
if terminal.IsTerminal(int(syscall.Stdin)) { //nolint
244244
fmt.Print(userQuery)
245-
pw, err := terminal.ReadPassword(int(syscall.Stdin)) // nolint
245+
pw, err := terminal.ReadPassword(int(syscall.Stdin)) //nolint
246246
if err != nil {
247247
return nil, err
248248
}

lnd/aezeed.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ func ReadAezeed(params *chaincfg.Params) (*hdkeychain.ExtendedKey, time.Time,
8989
"if your seed doesn't have a passphrase): ")
9090
var err error
9191
passphraseBytes, err = terminal.ReadPassword(
92-
int(syscall.Stdin), // nolint
92+
int(syscall.Stdin), //nolint
9393
)
9494
if err != nil {
9595
return nil, time.Unix(0, 0), err

lnd/graph.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
func AllNodeChannels(graph *lnrpc.ChannelGraph,
1010
nodePubKey string) []*lnrpc.ChannelEdge {
1111

12-
var result []*lnrpc.ChannelEdge // nolint:prealloc
12+
var result []*lnrpc.ChannelEdge //nolint:prealloc
1313
for _, edge := range graph.Edges {
1414
if edge.Node1Pub != nodePubKey && edge.Node2Pub != nodePubKey {
1515
continue
@@ -24,7 +24,7 @@ func AllNodeChannels(graph *lnrpc.ChannelGraph,
2424
func FindCommonEdges(graph *lnrpc.ChannelGraph, node1,
2525
node2 string) []*lnrpc.ChannelEdge {
2626

27-
var result []*lnrpc.ChannelEdge // nolint:prealloc
27+
var result []*lnrpc.ChannelEdge //nolint:prealloc
2828
for _, edge := range graph.Edges {
2929
if edge.Node1Pub != node1 && edge.Node2Pub != node1 {
3030
continue

lnd/signer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ func maybeTweakPrivKey(signDesc *input.SignDescriptor,
127127
// k is our private key, and P is the public key, we perform the following
128128
// operation:
129129
//
130-
// sx := k*P s := sha256(sx.SerializeCompressed())
130+
// sx := k*P s := sha256(sx.SerializeCompressed())
131131
func ECDH(privKey *btcec.PrivateKey, pub *btcec.PublicKey) ([32]byte, error) {
132132
var (
133133
pubJacobian btcec.JacobianPoint

0 commit comments

Comments
 (0)