mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-07 16:09:43 +02:00
style: fix prettier formatting in server.ts
Expand one-liner try/catch to multi-line to satisfy prettier check. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
+5
-1
@@ -583,7 +583,11 @@ export class WebServer extends EventEmitter {
|
|||||||
this.sendSSE(reply, 'init', this.getLightState());
|
this.sendSSE(reply, 'init', this.getLightState());
|
||||||
// Flush Cloudflare tunnel buffer with padding — ensures the init event
|
// Flush Cloudflare tunnel buffer with padding — ensures the init event
|
||||||
// (and any immediately following events) are delivered without proxy delay.
|
// (and any immediately following events) are delivered without proxy delay.
|
||||||
try { reply.raw.write(SSE_PADDING); } catch { /* client gone */ }
|
try {
|
||||||
|
reply.raw.write(SSE_PADDING);
|
||||||
|
} catch {
|
||||||
|
/* client gone */
|
||||||
|
}
|
||||||
|
|
||||||
req.raw.on('close', () => {
|
req.raw.on('close', () => {
|
||||||
this.sseClients.delete(reply);
|
this.sseClients.delete(reply);
|
||||||
|
|||||||
Reference in New Issue
Block a user