From 96e5706f790b5a93adfa4c7e841bc67f7af613da Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Sun, 7 Feb 2021 02:04:26 +1300 Subject: Preserve URI path from original request --- lib/POE/Component/Client/WebSocket.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/POE/Component/Client/WebSocket.pm b/lib/POE/Component/Client/WebSocket.pm index 642ac64..c2e2ccd 100644 --- a/lib/POE/Component/Client/WebSocket.pm +++ b/lib/POE/Component/Client/WebSocket.pm @@ -457,7 +457,7 @@ sub _socket_birth { ErrorEvent => 'socket_death', ); - my $request = HTTP::Request->new(GET => '/'); + my $request = HTTP::Request->new(GET => $heap->{uri}->{path}); $request->protocol('HTTP/1.1'); $request->header( Upgrade => 'WebSocket', -- cgit v1.2.3