Skip to content

Commit bf86387

Browse files
committed
chore: fix lint
1 parent 86ac0ea commit bf86387

1 file changed

Lines changed: 6 additions & 8 deletions

File tree

packages/raga-web-app/src/webApi.ts

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,23 +26,21 @@ class WebApi implements WebContextBridgeApi {
2626
private pendingCallbacks = new Map<string, ((payload: unknown) => void)[]>();
2727

2828
send(channel: ClientEventChannel, ...args: unknown[]): void {
29-
console.warn(`[WebApi] IPC send called with channel: ${String(channel)}`, args);
29+
console.warn(`[WebApi] IPC send called with channel: ${channel}`, args);
3030
// In a real implementation, this could send requests to a backend API
3131
}
3232

3333
handleOnce<T = unknown>(channel: ServerEventChannel, callback: (payload: T) => void): void {
34-
console.warn(`[WebApi] IPC handleOnce called with channel: ${String(channel)}`);
35-
const channelKey = String(channel);
36-
const callbacks = this.pendingCallbacks.get(channelKey) ?? [];
34+
console.warn(`[WebApi] IPC handleOnce called with channel: ${channel}`);
35+
const callbacks = this.pendingCallbacks.get(channel) ?? [];
3736
callbacks.push(callback as (payload: unknown) => void);
38-
this.pendingCallbacks.set(channelKey, callbacks);
37+
this.pendingCallbacks.set(channel, callbacks);
3938
}
4039

4140
waitForResponse<T = unknown>(channel: ServerEventChannel, _timeoutMs = 0): () => Promise<T> {
42-
console.warn(`[WebApi] IPC waitForResponse called with channel: ${String(channel)}`);
41+
console.warn(`[WebApi] IPC waitForResponse called with channel: ${channel}`);
4342
// Return a function that returns a rejected promise for now - in a real implementation this would wait for backend response
44-
return () =>
45-
Promise.reject(new Error(`Web API does not support IPC channel: ${String(channel)}`));
43+
return () => Promise.reject(new Error(`Web API does not support IPC channel: ${channel}`));
4644
}
4745

4846
getFilePath(file: File | null | undefined): string | undefined {

0 commit comments

Comments
 (0)