mirror of
https://github.com/signalapp/Signal-Server.git
synced 2026-12-01 13:06:47 +00:00
Don't reuse metadata in ServerInterceptorUtil
This commit is contained in:
1 parent
eedc4e23fe
commit
77c4962db8
1 file changed
+1
-3
+1
-3
@@ -15,8 +15,6 @@ public class ServerInterceptorUtil {
|
||||
@SuppressWarnings("rawtypes")
|
||||
private static final ServerCall.Listener NO_OP_LISTENER = new ServerCall.Listener<>() {};
|
||||
|
||||
private static final Metadata EMPTY_TRAILERS = new Metadata();
|
||||
|
||||
private ServerInterceptorUtil() {
|
||||
}
|
||||
|
||||
@@ -32,7 +30,7 @@ public class ServerInterceptorUtil {
|
||||
* @param <RespT> the type of response object returned by the server call
|
||||
*/
|
||||
public static <ReqT, RespT> ServerCall.Listener<ReqT> closeWithStatus(final ServerCall<ReqT, RespT> call, final Status status) {
|
||||
call.close(status, EMPTY_TRAILERS);
|
||||
call.close(status, new Metadata());
|
||||
|
||||
//noinspection unchecked
|
||||
return NO_OP_LISTENER;
|
||||
|
||||
Reference in new issue
Block a user