You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
create a room using server-side matchMaker.create('space', {})
join this room from browser from page http://localhost:8080 using colyseus.js:
new Client('ws:' + window.location.href.substring(window.location.protocol.length)).join('space')
The browser then sends a POST request to http://localhost:8080//matchmake/join/space. notice the double slash - a trailing slash was added to the client .endpoint somewhere along the way. The server parses the path accordingly (see here and here )
3. However, when I use the same code in an inner page http://localhost:8080/game1 the request goes to http://localhost:8080/game1/matchmake/join/space and the server catches it but answers with {"code":4210,"error":"invalid method \"matchmake\""}.
I'm pretty sure this was just introduced in 0.13.0 .
IMO all matchmakers requests should go to https://${client.endpoint}/matchmake/... (single slash), and the server should be more strict with its path tests.
The text was updated successfully, but these errors were encountered:
Steps to Reproduce (for bugs)
matchMaker.create('space', {})
http://localhost:8080
using colyseus.js:The browser then sends a POST request to
http://localhost:8080//matchmake/join/space
. notice the double slash - a trailing slash was added to the client.endpoint
somewhere along the way. The server parses the path accordingly (see here and here )3. However, when I use the same code in an inner page
http://localhost:8080/game1
the request goes tohttp://localhost:8080/game1/matchmake/join/space
and the server catches it but answers with{"code":4210,"error":"invalid method \"matchmake\""}
.I'm pretty sure this was just introduced in 0.13.0 .
IMO all matchmakers requests should go to
https://${client.endpoint}/matchmake/...
(single slash), and the server should be more strict with its path tests.The text was updated successfully, but these errors were encountered: