fix: fetch block data for sortKey on viewState evaluation - remove BlockData type
This commit is contained in:
@@ -45,7 +45,6 @@ import { ContractInteractionState } from './states/ContractInteractionState';
|
|||||||
import { Buffer, Crypto } from 'warp-isomorphic';
|
import { Buffer, Crypto } from 'warp-isomorphic';
|
||||||
import { VrfPluginFunctions } from '../core/WarpPlugin';
|
import { VrfPluginFunctions } from '../core/WarpPlugin';
|
||||||
import { createData, DataItem, Signer, tagsExceedLimit } from 'warp-arbundles';
|
import { createData, DataItem, Signer, tagsExceedLimit } from 'warp-arbundles';
|
||||||
import { BlockData } from 'arweave/node/blocks';
|
|
||||||
|
|
||||||
interface InteractionManifestData {
|
interface InteractionManifestData {
|
||||||
[path: string]: string;
|
[path: string]: string;
|
||||||
@@ -852,7 +851,7 @@ export class HandlerBasedContract<State> implements Contract<State> {
|
|||||||
|
|
||||||
const blockHeight = sortKey ? await this._sorter.extractBlockHeight(sortKey) : undefined;
|
const blockHeight = sortKey ? await this._sorter.extractBlockHeight(sortKey) : undefined;
|
||||||
|
|
||||||
let currentBlockData: BlockData;
|
let currentBlockData;
|
||||||
if (this.warp.environment == 'mainnet' && !(this.warp.interactionsLoader.type() === 'arweave')) {
|
if (this.warp.environment == 'mainnet' && !(this.warp.interactionsLoader.type() === 'arweave')) {
|
||||||
currentBlockData = await this._arweaveWrapper.warpGwBlock();
|
currentBlockData = await this._arweaveWrapper.warpGwBlock();
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user