Skip to content

Commit 3f90caf

Browse files
committed
fix already fixed checks that came in new
1 parent c22bb68 commit 3f90caf

File tree

4 files changed

+14
-11
lines changed

4 files changed

+14
-11
lines changed

examples/features/advancedtls/client/main.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
*
1717
*/
1818

19+
// Binary client is an example client demonstrating use of advancedtls,
20+
// to set up a secure gRPC client connection with various TLS authentication
21+
// methods.
1922
package main
2023

2124
import (

examples/features/advancedtls/server/main.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
*
1717
*/
1818

19+
// Binary server is an example client demonstrating how to set up a secure gRPC
20+
// server using advancedtls.
1921
package main
2022

2123
import (

rpc_util.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -791,9 +791,9 @@ func checkRecvPayload(pf payloadFormat, recvCompress string, haveCompressor bool
791791
if !haveCompressor {
792792
if isServer {
793793
return status.Newf(codes.Unimplemented, "grpc: Decompressor is not installed for grpc-encoding %q", recvCompress)
794-
} else {
795-
return status.Newf(codes.Internal, "grpc: Decompressor is not installed for grpc-encoding %q", recvCompress)
796794
}
795+
return status.Newf(codes.Internal, "grpc: Decompressor is not installed for grpc-encoding %q", recvCompress)
796+
797797
}
798798
default:
799799
return status.Newf(codes.Internal, "grpc: received unexpected payload format %d", pf)

scripts/revive.toml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,23 @@
33
[rule.context-as-argument]
44
[rule.context-keys-type]
55
[rule.dot-imports]
6+
[rule.errorf]
67
[rule.error-return]
78
[rule.error-strings]
89
[rule.error-naming]
910
[rule.increment-decrement]
10-
[rule.var-naming]
11-
[rule.var-declaration]
11+
[rule.indent-error-flow]
12+
[rule.package-comments]
1213
[rule.range]
1314
[rule.receiver-naming]
15+
[rule.superfluous-else]
1416
[rule.time-naming]
17+
[rule.var-naming]
1518
[rule.unexported-return]
16-
[rule.indent-error-flow]
17-
[rule.errorf]
18-
[rule.superfluous-else]
1919
[rule.unused-parameter]
2020
[rule.unreachable-code]
21+
[rule.var-declaration]
22+
[rule.use-any]
2123

2224
# Disabled rules
2325
# https://github.com/grpc/grpc-go/issues/7444 to track TODO(s)
@@ -26,8 +28,4 @@
2628
[rule.exported]
2729
Disabled = true # TODO: Enable after existing issues are fixed
2830
[rule.redefines-builtin-id]
29-
Disabled = true # TODO: Enable after existing issues are fixed
30-
[rule.package-comments]
31-
Disabled = true # TODO: Enable after existing issues are fixed
32-
[rule.use-any]
3331
Disabled = true # TODO: Enable after existing issues are fixed

0 commit comments

Comments
 (0)