From 1091f944d1af02e27a770d78e87e6c55c902decd Mon Sep 17 00:00:00 2001 From: Marek Gradzki Date: Mon, 6 Aug 2018 08:16:48 +0200 Subject: HoneycombDOMRpcService: remove unnecessary cast to Function Fixes issue reported by Sonar. Change-Id: I083eb089f1ccd691a2015eaa401fe5acf7c59d49 Signed-off-by: Marek Gradzki --- .../src/main/java/io/fd/honeycomb/rpc/HoneycombDOMRpcService.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/infra/rpc/impl/src/main/java/io/fd/honeycomb/rpc/HoneycombDOMRpcService.java b/infra/rpc/impl/src/main/java/io/fd/honeycomb/rpc/HoneycombDOMRpcService.java index 01adbd6da..d951ff962 100644 --- a/infra/rpc/impl/src/main/java/io/fd/honeycomb/rpc/HoneycombDOMRpcService.java +++ b/infra/rpc/impl/src/main/java/io/fd/honeycomb/rpc/HoneycombDOMRpcService.java @@ -40,9 +40,7 @@ import org.opendaylight.yangtools.yang.model.api.SchemaPath; public final class HoneycombDOMRpcService implements DOMRpcService { private static final Function ANY_EX_TO_RPC_EXCEPTION_MAPPER = - (Function) e -> (e instanceof DOMRpcException) - ? (DOMRpcException) e - : new RpcException("RPC failed", e); + e -> (e instanceof DOMRpcException) ? (DOMRpcException) e : new RpcException("RPC failed", e); private final BindingNormalizedNodeSerializer serializer; private final RpcRegistry rpcRegistry; -- cgit 1.2.3-korg