Skip to content
Snippets Groups Projects
Commit 40fcaed8 authored by echicken's avatar echicken :chicken:
Browse files

Content-Type not Content-type; delay 1000 ms between event source scans.

parent b29f0fa8
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
...@@ -7,7 +7,7 @@ load(settings.web_lib + 'request.js'); ...@@ -7,7 +7,7 @@ load(settings.web_lib + 'request.js');
js.time_limit = 0; js.time_limit = 0;
http_reply.header['Cache-Control'] = 'no-cache'; http_reply.header['Cache-Control'] = 'no-cache';
http_reply.header['Content-type'] = 'text/event-stream'; http_reply.header['Content-Type'] = 'text/event-stream';
http_reply.header['X-Accel-Buffering'] = 'no'; // probably not needed by everyone (nginx) http_reply.header['X-Accel-Buffering'] = 'no'; // probably not needed by everyone (nginx)
const keepalive = 15; const keepalive = 15;
...@@ -53,6 +53,6 @@ while (client.socket.is_connected) { ...@@ -53,6 +53,6 @@ while (client.socket.is_connected) {
delete callbacks[e]; delete callbacks[e];
} }
}); });
mswait(50); mswait(1000);
ping(); ping();
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment