MCPcopy Create free account
hub / github.com/subquery/subql / updateDynamicDs

Method updateDynamicDs

packages/node/src/blockchain.service.ts:170–184  ·  view source on GitHub ↗
(
    params: DatasourceParams,
    dsObj: SubstrateProjectDs,
  )

Source from the content-addressed store, hash-verified

168
169 // eslint-disable-next-line @typescript-eslint/require-await
170 async updateDynamicDs(
171 params: DatasourceParams,
172 dsObj: SubstrateProjectDs,
173 ): Promise<void> {
174 if (isCustomDs(dsObj)) {
175 dsObj.processor.options = {
176 ...dsObj.processor.options,
177 ...params.args,
178 };
179 // TODO needs dsProcessorService
180 // await this.dsProcessorService.validateCustomDs([dsObj]);
181 } else if (isRuntimeDs(dsObj)) {
182 // XXX add any modifications to the ds here
183 }
184 }
185
186 async getSafeApi(block: LightBlockContent | BlockContent): Promise<ApiAt> {
187 const runtimeVersion = !isFullBlock(block)

Callers

nothing calls this directly

Calls 2

isCustomDsFunction · 0.90
isRuntimeDsFunction · 0.90

Tested by

no test coverage detected