(
blockNums: number[],
)
| 71 | |
| 72 | @mainThreadOnly() |
| 73 | async fetchBlocks( |
| 74 | blockNums: number[], |
| 75 | ): Promise<IBlock<BlockContent>[] | IBlock<LightBlockContent>[]> { |
| 76 | const specChanged = await this.runtimeService.specChanged( |
| 77 | blockNums[blockNums.length - 1], |
| 78 | ); |
| 79 | |
| 80 | // If specVersion not changed, a known overallSpecVer will be pass in |
| 81 | // Otherwise use api to fetch runtimes |
| 82 | return this.apiService.fetchBlocks( |
| 83 | blockNums, |
| 84 | specChanged ? undefined : this.runtimeService.parentSpecVersion, |
| 85 | ); |
| 86 | } |
| 87 | |
| 88 | async fetchBlockWorker( |
| 89 | worker: IIndexerWorker, |
nothing calls this directly
no test coverage detected