api-sdk-ts
api-sdk-ts copied to clipboard
Select fields does not work as expected
const liveBlocks = await blocksGet({
sort: {
desc: 'level',
},
limit: this.liveBlocksLimit,
select: { fields: ['hash', 'timestamp'] },
...filters,
});
Returns plain array of hashes although should return list of objects: https://api.tzkt.io/v1/blocks?select.fields=hash,timestamp&limit=2
Probably string array is not joined.
We also need to handle the edge case with a single feed (maybe return Block[] | string[]
)