Skip to content

Commit 2f05145

Browse files
actions-userprocesstrader
authored andcommitted
chore: format code
1 parent 375d9f1 commit 2f05145

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

packages/opencode/src/session/index.ts

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ export namespace Session {
325325
for (const child of await children(sessionID)) {
326326
await remove(child.id)
327327
}
328-
await unshare(sessionID).catch(() => { })
328+
await unshare(sessionID).catch(() => {})
329329
for (const msg of await Storage.list(["message", sessionID])) {
330330
for (const part of await Storage.list(["part", msg.at(-1)!])) {
331331
await Storage.remove(part)
@@ -428,11 +428,10 @@ export namespace Session {
428428
return value
429429
}
430430

431-
const cacheWriteTokens =
432-
(input.metadata?.["anthropic"]?.["cacheCreationInputTokens"] ??
433-
// @ts-expect-error
434-
input.metadata?.["bedrock"]?.["usage"]?.["cacheWriteInputTokens"] ??
435-
0) as number
431+
const cacheWriteTokens = (input.metadata?.["anthropic"]?.["cacheCreationInputTokens"] ??
432+
// @ts-expect-error
433+
input.metadata?.["bedrock"]?.["usage"]?.["cacheWriteInputTokens"] ??
434+
0) as number
436435

437436
const tokens = {
438437
input: safe(adjustedInputTokens),

packages/opencode/src/session/processor.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ export namespace SessionProcessor {
342342
message: error.data.message.includes("Overloaded") ? "Provider is overloaded" : error.data.message,
343343
next: Date.now() + delay,
344344
})
345-
await SessionRetry.sleep(delay, input.abort).catch(() => { })
345+
await SessionRetry.sleep(delay, input.abort).catch(() => {})
346346
continue
347347
}
348348
input.assistantMessage.error = error

0 commit comments

Comments
 (0)