diff options
| author | Spencer Tung <spencertung@google.com> | 2017-06-28 11:18:03 -0700 |
|---|---|---|
| committer | Han-Wen Nienhuys <hanwen@google.com> | 2017-07-06 07:43:13 +0000 |
| commit | d625dfd80595a76324dea1452ceb9cfbcaee8e3e (patch) | |
| tree | c1b0b2ccb057c529771e06026f157774897630cd /ssh/client_auth_test.go | |
| parent | b286ef4198388fdb0e4ae62be12820df5da9b4c2 (diff) | |
| download | go-x-crypto-d625dfd80595a76324dea1452ceb9cfbcaee8e3e.tar.xz | |
ssh: fix if/else returns to adhere to Go style guidelines
Change-Id: Iea55e6397c49046d7d3e0eb66a392f1779d91802
Reviewed-on: https://go-review.googlesource.com/47050
Reviewed-by: Han-Wen Nienhuys <hanwen@google.com>
Run-TryBot: Han-Wen Nienhuys <hanwen@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'ssh/client_auth_test.go')
| -rw-r--r-- | ssh/client_auth_test.go | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/ssh/client_auth_test.go b/ssh/client_auth_test.go index 2e9672a..89e0d92 100644 --- a/ssh/client_auth_test.go +++ b/ssh/client_auth_test.go @@ -359,9 +359,8 @@ func testPermissionsPassing(withPermissions bool, t *testing.T) { PublicKeyCallback: func(conn ConnMetadata, key PublicKey) (*Permissions, error) { if conn.User() == "nopermissions" { return nil, nil - } else { - return &Permissions{}, nil } + return &Permissions{}, nil }, } serverConfig.AddHostKey(testSigners["rsa"]) @@ -510,9 +509,8 @@ func TestClientAuthMaxAuthTries(t *testing.T) { n-- if n == 0 { return "right", nil - } else { - return "wrong", nil } + return "wrong", nil }), tries), }, HostKeyCallback: InsecureIgnoreHostKey(), |
