Skip to content

Commit

Permalink
Add prettier to flake.nix
Browse files Browse the repository at this point in the history
  • Loading branch information
DogLooksGood committed Nov 26, 2024
1 parent d641be6 commit b127688
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 14 deletions.
1 change: 1 addition & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
rust-analyzer
nodePackages.typescript
nodePackages.typescript-language-server
nodePackages.prettier
zellij
];
RUST_LOG = "info,hyper=error,parse_headers=error,encode_headers=error,wasmer_compiler_cranelift=info,solana_rpc_client=debug,solana_client=debug,jsonrpsee_server=info";
Expand Down
24 changes: 10 additions & 14 deletions js/sdk-core/src/base-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -310,11 +310,10 @@ export class BaseClient {
}

if (!err) {
await this.__invokeEventCallback(event,
{
isCheckpoint: effects?.checkpoint !== undefined,
source,
})
await this.__invokeEventCallback(event, {
isCheckpoint: effects?.checkpoint !== undefined,
source,
})
}

if (err) {
Expand Down Expand Up @@ -394,19 +393,16 @@ export class BaseClient {
try {
await this.__checkStateSha(frame.stateSha, 'checkpoint-state-sha-mismatch')
let histLen = frame.histories.length
for (let i = 0; i < histLen; i ++) {
for (let i = 0; i < histLen; i++) {
const h = frame.histories[i]
const remaining = histLen - i - 1
await this.__handleEvent(h.event, h.timestamp, h.stateSha,
{ kind: 'backlog', remaining }
)
await this.__handleEvent(h.event, h.timestamp, h.stateSha, { kind: 'backlog', remaining })
}
if (histLen === 0) {
this.__invokeEventCallback(undefined,
{
isCheckpoint: true,
source: { kind: 'backlog', remaining: 0 }
})
this.__invokeEventCallback(undefined, {
isCheckpoint: true,
source: { kind: 'backlog', remaining: 0 },
})
}
} finally {
console.groupEnd()
Expand Down

0 comments on commit b127688

Please sign in to comment.