Code quality

This commit is contained in:
Felipe Augusto Rieck 2025-08-04 18:19:14 -03:00
parent d4eb61f64d
commit fb11f3f99c

View File

@ -30,7 +30,7 @@ export class WebsocketController extends EventController implements EventControl
const url = new URL(req.url || '', 'http://localhost'); const url = new URL(req.url || '', 'http://localhost');
const params = new URLSearchParams(url.search); const params = new URLSearchParams(url.search);
const remoteAddress = req.socket.remoteAddress; const { remoteAddress } = req.socket;
const isLocalhost = const isLocalhost =
remoteAddress === '127.0.0.1' || remoteAddress === '::1' || remoteAddress === '::ffff:127.0.0.1'; remoteAddress === '127.0.0.1' || remoteAddress === '::1' || remoteAddress === '::ffff:127.0.0.1';