This commit is contained in:
Horis
2023-04-16 14:51:15 +08:00
parent 802847649c
commit 068c77da74
2 changed files with 5 additions and 1 deletions

View File

@@ -98,7 +98,7 @@ const debug = (
const socket = new WebSocket(url);
socket.onopen = () => {
socket.send(`{"tag":"${sourceUrl}", "key":"${searchKey}"}`);
socket.send(JSON.stringify({ tag: sourceUrl, key: searchKey }));
};
socket.onmessage = ({ data }) => onReceive(data);