Backport: Fix subprotocols

Broken by b1dee9478815b22bf5fee3ee9e44321d4bb46c91

(cherry picked from commit 58ca1978eacdb030233b5f7351cc1b063da289ee)