Skip to content

Commit 47f37e9

Browse files
committed
fix(lint): resolve useImportType and useIterableCallbackReturn issues
- Convert AddressInfo import to type-only import in webui-fixture-server - Consolidate inline type modifiers into import type in camera-utils - Replace forEach with for-of loop for WebSocket client cleanup
1 parent d67e916 commit 47f37e9

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

e2e/helpers/webui-fixture-server.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
import { readFile } from 'node:fs/promises';
66
import { createServer, type IncomingMessage, type Server, type ServerResponse } from 'node:http';
7-
import { AddressInfo } from 'node:net';
7+
import type { AddressInfo } from 'node:net';
88
import path from 'node:path';
99
import { WebSocketServer } from 'ws';
1010

@@ -168,7 +168,9 @@ export async function startWebUiFixtureServer(
168168
baseUrl: `http://127.0.0.1:${port}`,
169169
requests,
170170
async close() {
171-
webSocketServer.clients.forEach((client) => client.close());
171+
for (const client of webSocketServer.clients) {
172+
client.close();
173+
}
172174
webSocketServer.close();
173175
await closeServer(server);
174176
},

src/utils/camera-utils.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,12 @@
3333
*/
3434

3535
import { getPrinterContextManager } from '../managers/PrinterContextManager';
36-
import {
37-
type CameraStreamType,
38-
type CameraUrlResolutionParams,
39-
type CameraUrlValidationResult,
40-
type CameraUserConfig,
41-
type ResolvedCameraConfig,
36+
import type {
37+
CameraStreamType,
38+
CameraUrlResolutionParams,
39+
CameraUrlValidationResult,
40+
CameraUserConfig,
41+
ResolvedCameraConfig,
4242
} from '../types/camera';
4343
import { normalizeCustomCameraSettings } from './printerSettingsDefaults';
4444

0 commit comments

Comments
 (0)