Skip to content

Commit a4b2fa9

Browse files
committed
style: format code with biome
1 parent ced211d commit a4b2fa9

5 files changed

Lines changed: 19 additions & 14 deletions

File tree

src/plugin/pty/wildcard.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export function all(input: string, patterns: Record<string, string>): string | u
1515
const sorted = Object.entries(patterns).sort(
1616
(a, b) => a[0].length - b[0].length || a[0].localeCompare(b[0])
1717
)
18-
let result: string | undefined
18+
let result: string | undefined
1919
for (const [pattern, value] of sorted) {
2020
if (match(input, pattern)) {
2121
result = value
@@ -31,7 +31,7 @@ export function allStructured(
3131
const sorted = Object.entries(patterns).sort(
3232
(a, b) => a[0].length - b[0].length || a[0].localeCompare(b[0])
3333
)
34-
let result: string | undefined
34+
let result: string | undefined
3535
for (const [pattern, value] of sorted) {
3636
const parts = pattern.split(/\s+/)
3737
const firstPart = parts[0]

src/web/client/components/error-boundary.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,8 @@ export class ErrorBoundary extends React.Component<ErrorBoundaryProps, ErrorBoun
6262
</pre>
6363
</details>
6464
<div style={{ marginTop: '15px', display: 'flex', gap: '10px' }}>
65-
<button type="button"
65+
<button
66+
type="button"
6667
onClick={this.handleReset}
6768
style={{
6869
padding: '8px 16px',
@@ -75,7 +76,8 @@ export class ErrorBoundary extends React.Component<ErrorBoundaryProps, ErrorBoun
7576
>
7677
Try Again
7778
</button>
78-
<button type="button"
79+
<button
80+
type="button"
7981
onClick={() => window.location.reload()}
8082
style={{
8183
padding: '8px 16px',

src/web/client/hooks/use-web-socket.ts

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,14 +70,18 @@ export function useWebSocket({
7070
JSON.stringify({ type: 'subscribe', sessionId: autoSelected.id })
7171
)
7272
} else {
73-
setTimeout((autoSelected) => {
74-
const retryReadyState = wsRef.current?.readyState
75-
if (retryReadyState === WebSocket.OPEN && wsRef.current) {
76-
wsRef.current.send(
77-
JSON.stringify({ type: 'subscribe', sessionId: autoSelected.id })
78-
)
79-
}
80-
}, RETRY_DELAY, autoSelected)
73+
setTimeout(
74+
(autoSelected) => {
75+
const retryReadyState = wsRef.current?.readyState
76+
if (retryReadyState === WebSocket.OPEN && wsRef.current) {
77+
wsRef.current.send(
78+
JSON.stringify({ type: 'subscribe', sessionId: autoSelected.id })
79+
)
80+
}
81+
},
82+
RETRY_DELAY,
83+
autoSelected
84+
)
8185
}
8286
}
8387
}

src/web/shared/types.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import type { PTYSessionInfo, PTYStatus, SpawnOptions } from '../../plugin/pty/t
33
export type { PTYSessionInfo, PTYStatus, HealthResponse }
44

55
export class CustomError extends Error {
6-
76
override name = 'CustomError'
87
prettyPrintColor: string = Bun.inspect(this, { colors: true, depth: 10 })
98
prettyPrintNoColor: string = Bun.stripANSI(this.prettyPrintColor)

test/e2e/fixtures.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ export const test = base.extend<TestFixtures, WorkerFixtures>({
6464
console.error(`[W${workerIndex} ERR] ${data}`)
6565
})
6666

67-
proc.on('exit', (_code, _signal) => { })
67+
proc.on('exit', (_code, _signal) => {})
6868

6969
try {
7070
// Wait for server to write port file

0 commit comments

Comments
 (0)