mcp: fix typo in protocol version comment (#1156)

`protcol` should be `protocol`.

The comment sits above the `Mcp-Protocol-Version` header lookup, and the
surrounding code uses `protocolVersion` and
`protocolVersionFromContext`, so this is the only place in the package
where the word is misspelled.
This commit is contained in:
Recoordinate 2026-08-10 19:10:06 +12:00 • committed by GitHub
commit e9a85e285f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1524,7 +1524,7 @@ func (c *streamableServerConn) servePOST(w http.ResponseWriter, req *http.Reques
metaVersion, _ = meta[MetaKeyProtocolVersion].(string)
}
if protocolVersion >= protocolVersion20260728 || metaVersion != "" {
// Extract again the protcol version from the context to see what the client
// Extract again the protocol version from the context to see what the client
// is advertising in the Mcp-Protocol-Version HTTP header.
headerVersion := protocolVersionFromContext(req.Context())
// server/discover is exempt from the stateful