Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Message to support updateSerial #1916

Merged
merged 1 commit into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ably.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2281,7 +2281,7 @@
* and {@link ChannelOptions}, or returns the existing channel object.
*
* @experimental This is a preview feature and may change in a future non-major release.
* This experimental method allows you to create custom realtime data feeds by selectively subscribing

Check warning on line 2284 in ably.d.ts

View workflow job for this annotation

GitHub Actions / lint

Expected no lines between tags
* to receive only part of the data from the channel.
* See the [announcement post](https://pages.ably.com/subscription-filters-preview) for more information.
*
Expand Down Expand Up @@ -2356,9 +2356,9 @@
*/
updatedAt?: number;
/**
* If a `deletion` operation was applied to this message, this will be the timestamp the deletion occurred.
* The serial of the operation that updated this message.
*/
deletedAt?: number;
updateSerial?: string;
/**
* If this message resulted from an operation, this will contain the operation details.
*/
Expand Down
6 changes: 3 additions & 3 deletions src/common/lib/types/message.ts
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ class Message {
refSerial?: string;
refType?: string;
updatedAt?: number;
deletedAt?: number;
updateSerial?: string;
operation?: API.Operation;

/**
Expand Down Expand Up @@ -378,7 +378,7 @@ class Message {
refSerial: this.refSerial,
refType: this.refType,
updatedAt: this.updatedAt,
deletedAt: this.deletedAt,
updateSerial: this.updateSerial,
operation: this.operation,
encoding,
data,
Expand Down Expand Up @@ -407,7 +407,7 @@ class Message {
if (this.refSerial) result += '; refSerial=' + this.refSerial;
if (this.refType) result += '; refType=' + this.refType;
if (this.updatedAt) result += '; updatedAt=' + this.updatedAt;
if (this.deletedAt) result += '; deletedAt=' + this.deletedAt;
if (this.updateSerial) result += '; updateSerial=' + this.updateSerial;
if (this.operation) result += '; operation=' + JSON.stringify(this.operation);
result += ']';
return result;
Expand Down
Loading