diff --git a/src/Driver/HttpDriverMiddleware.php b/src/Driver/HttpDriverMiddleware.php index 7467160a..5fc3209c 100644 --- a/src/Driver/HttpDriverMiddleware.php +++ b/src/Driver/HttpDriverMiddleware.php @@ -13,9 +13,4 @@ public function createHttpDriver( ErrorHandler $errorHandler, Client $client, ): HttpDriver; - - /** - * @return list - */ - public function getApplicationLayerProtocols(HttpDriverMiddleware $next): array; } diff --git a/src/SocketHttpServer.php b/src/SocketHttpServer.php index 398c411f..cba25068 100644 --- a/src/SocketHttpServer.php +++ b/src/SocketHttpServer.php @@ -197,8 +197,8 @@ public function expose(SocketAddress|string $socketAddress, BindContext|QuicServ $socketAddress = SocketAddress\fromString($socketAddress); } - $name = $socketAddress->toString(); - if (isset($this->addresses[$name]) && ($bindContext instanceof QuicServerConfig) == ($this->addresses[$name][1] instanceof QuicServerConfig)) { + $name = ($bindContext instanceof QuicServerConfig ? "quic-" : "") . $socketAddress->toString(); + if (isset($this->addresses[$name])) { throw new \Error(\sprintf('Already exposing %s on HTTP server', $name)); }