diff --git a/client/src/utils/SocketIO.js b/client/src/utils/SocketIO.js index e84a167fa..acf80883c 100644 --- a/client/src/utils/SocketIO.js +++ b/client/src/utils/SocketIO.js @@ -1,17 +1,4 @@ -import {io} from "socket.io-client"; -import {config} from "../api"; - let initializedSocket = null; -export const socket = initializedSocket ? Promise.resolve(initializedSocket) : - config().then(res => { - initializedSocket = io(res.socket_url, { - transports: ["websocket"], - cors: { - origin: `${window.location.protocol}//${window.location.host}/`, - }, - }); - return initializedSocket; - }); - +export const socket = initializedSocket ? Promise.resolve(initializedSocket) : Promise.resolve({on: () => true}) export const subscriptionIdCookieName = "subscription_id";