fix: remove redundant entrypoint.FromCtx(ctx) call

This commit is contained in:
yusing
2026-02-06 23:29:43 +08:00
parent f5ab86c233
commit f2939fb6e8

View File

@@ -59,7 +59,7 @@ func (s *TCPTCPStream) ListenAndServe(ctx context.Context, preDial, onRead netty
}
if ep := entrypoint.FromCtx(ctx); ep != nil {
if proxyProto := entrypoint.FromCtx(ctx).SupportProxyProtocol(); proxyProto {
if proxyProto := ep.SupportProxyProtocol(); proxyProto {
s.listener = &proxyproto.Listener{Listener: s.listener}
}
}