Use JSON body durr
This commit is contained in:
parent
b09c9e6f06
commit
096e69259f
2
index.js
2
index.js
|
@ -22,7 +22,7 @@ app.put('/api/connect/:jobid', (req, res) => {
|
||||||
ws_[id] = {};
|
ws_[id] = {};
|
||||||
ws_[id].jobid = req.params.jobid; // Roblox server ID, checked on all requests as a sort of username alongside the ID
|
ws_[id].jobid = req.params.jobid; // Roblox server ID, checked on all requests as a sort of username alongside the ID
|
||||||
ws_[id].message = "";
|
ws_[id].message = "";
|
||||||
ws_[id].connection = new WebSocket(req.body);
|
ws_[id].connection = new WebSocket(req.body.url);
|
||||||
ws_[id].connection.on('message', function(data) {
|
ws_[id].connection.on('message', function(data) {
|
||||||
ws_[id].message = data;
|
ws_[id].message = data;
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue