nextPage of liveMessages not working in ts-sdk

Hello,
I followed TypeScript Live Objects/Collections - Amity Docs for the Live Message collection. However, it seems only handle the prevPage case, so I can’t get the right nextPage like liveChannels does.
Please check. Thanks.

Additionally, when I change from channelId1 to channelId2 and back to channelId1, the messages result is still of the channelId2. It seems the result always represents the latest query.

Hey @baodongle,

  1. Seems like a bug on the SDK, I’ll keep you updated on this one. I’ll try to add this in the current release. If not, it can be part of the next one.
  2. Unable to reproduce this, do you mean channelId or subChannelId

Thank you for your replying, @cijin. I mean subChannelId.

  1. I’ve just realized that localReadToSegment is usually 1 less than messageCount. Please explain why. Thank you.
  1. startReading and stopReading seem not to work. I think it happens because I didn’t touch subChannel records.
const subChannel = pullFromCache<Amity.SubChannel>(['subChannel', 'get', subChannelId]);
if (!subChannel) {
  return;
}

Hey @baodongle,

As I mentioned prior, read count is a work in progress. The SDK sets localReadToSegment as messageCount - 1. It’s only a placeholder till the actual work is completed.

Same goes for startReading / stopReading.

The support team can keep you in the loop when the marker service is ready for use.

C.C. @amitysupport

1 Like

Hi @baodongle

We’re fixing this in our current release which should be done by the end of this month.
We’ll inform you once it’s released.

Any other issues please don’t hesitate to let us know.

Thank you,
Amity Support

1 Like

Hi @baodongle

All issues discussed are now fixed.

Thank you,
Amity Support