mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
simpler socketio setup URL handling
This commit is contained in:
parent
2a78eb96d0
commit
0fbd26e9bf
@ -22,9 +22,9 @@ import * as InvokeAI from '../invokeai';
|
|||||||
* some new action to handle whatever data was sent from the server.
|
* some new action to handle whatever data was sent from the server.
|
||||||
*/
|
*/
|
||||||
export const socketioMiddleware = () => {
|
export const socketioMiddleware = () => {
|
||||||
const { hostname, port } = new URL(window.location.href);
|
const { origin } = new URL(window.location.href);
|
||||||
|
|
||||||
const socketio = io(`http://${hostname}:${port}`, {
|
const socketio = io(origin, {
|
||||||
timeout: 60000,
|
timeout: 60000,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user