( walletAddress: string )
| 430 | * Returns the remote version, or null if no shards exist. |
| 431 | */ |
| 432 | export async function checkRemoteVersion( |
| 433 | walletAddress: string |
| 434 | ): Promise<number | null> { |
| 435 | const shards = await queryShards(walletAddress); |
| 436 | const dataShards = shards.filter( |
| 437 | (s) => s.type === "delta" || s.type === "snapshot" |
| 438 | ); |
| 439 | if (dataShards.length === 0) return null; |
| 440 | return Math.max(...dataShards.map((s) => s.version)); |
| 441 | } |
nothing calls this directly
no test coverage detected