fix: remove hardcoded reference to localhost
This commit is contained in:
parent
97c8598717
commit
ed709210e3
@ -46,7 +46,7 @@ export default function CodeEditor({
|
|||||||
// Initialize socket connection if it doesn't exist
|
// Initialize socket connection if it doesn't exist
|
||||||
if (!socketRef.current) {
|
if (!socketRef.current) {
|
||||||
socketRef.current = io(
|
socketRef.current = io(
|
||||||
`http://localhost:${process.env.NEXT_PUBLIC_SERVER_PORT}?userId=${userData.id}&sandboxId=${sandboxData.id}`,
|
`${window.location.protocol}//${window.location.hostname}:${process.env.NEXT_PUBLIC_SERVER_PORT}?userId=${userData.id}&sandboxId=${sandboxData.id}`,
|
||||||
{
|
{
|
||||||
timeout: 2000,
|
timeout: 2000,
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user