Merge pull request #43623 from madmiraal/fix-js-lgtm-warning

Fix godot_js_websocket_send function unused assignment.
This commit is contained in:
Fabio Alessandrelli 2020-11-17 20:37:51 +01:00 committed by GitHub
commit aa15f7619a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -162,10 +162,8 @@ var GodotWebSocket = {
for(i = 0; i < p_buf_len; i++) {
bytes_array[i] = getValue(p_buf + i, 'i8');
}
var out = bytes_array;
if (p_raw) {
out = bytes_array.buffer;
} else {
var out = bytes_array.buffer;
if (!p_raw) {
out = new TextDecoder("utf-8").decode(bytes_array);
}
return GodotWebSocket.send(p_id, out);