Skip to content

Commit

Permalink
all: fix lint warnings (#6658)
Browse files Browse the repository at this point in the history
  • Loading branch information
creamsoup committed Jan 30, 2020
1 parent f04c492 commit 2acca6e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
Expand Up @@ -104,7 +104,6 @@ ConfigOrError parseLoadBalancingConfigPolicyInternal(
* Gets a list from an object for the given key. Copy of
* {@link io.grpc.internal.ServiceConfigUtil#getList}.
*/
@SuppressWarnings("unchecked")
@Nullable
private static List<?> getList(Map<String, ?> obj, String key) {
assert key != null;
Expand Down
2 changes: 1 addition & 1 deletion netty/src/main/java/io/grpc/netty/ProtocolNegotiators.java
Expand Up @@ -276,7 +276,7 @@ protected void protocolNegotiationEventTriggered(ChannelHandlerContext ctx) {
} else {
nettyProxyHandler = new HttpProxyHandler(address, userName, password);
}
ctx.pipeline().addBefore(ctx.name(), /* newName= */ null, nettyProxyHandler);
ctx.pipeline().addBefore(ctx.name(), /* name= */ null, nettyProxyHandler);
}

@Override
Expand Down
4 changes: 2 additions & 2 deletions xds/src/main/java/io/grpc/xds/XdsClientImpl.java
Expand Up @@ -699,7 +699,7 @@ private void handleCdsResponse(DiscoveryResponse cdsResponse) {
// Management server is required to always send newly requested resources, even if they
// may have been sent previously (proactively). Thus, client does not need to cache
// unrequested resources.
if (!clusterWatchers.keySet().contains(clusterName)) {
if (!clusterWatchers.containsKey(clusterName)) {
continue;
}
ClusterUpdate.Builder updateBuilder = ClusterUpdate.newBuilder();
Expand Down Expand Up @@ -1378,7 +1378,7 @@ static boolean matchHostName(String hostName, String pattern) {
* containing {@link com.google.protobuf.Any} fields.
*/
@VisibleForTesting
static class MessagePrinter {
static final class MessagePrinter {
private final JsonFormat.Printer printer;

@VisibleForTesting
Expand Down

0 comments on commit 2acca6e

Please sign in to comment.