Skip to content

Commit

Permalink
Add missing resolved field.
Browse files Browse the repository at this point in the history
  • Loading branch information
Nihlus committed Oct 29, 2023
1 parent 6111fea commit c33fb31
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,11 @@ public interface IMessage : IPartialMessage
/// </summary>
new Optional<int> Position { get; }

/// <summary>
/// Gets data for users, members, channels, and roles in the message's auto-populated select menus.
/// </summary>
new Optional<IApplicationCommandInteractionDataResolved> Resolved { get; }

/// <inheritdoc/>
Optional<Snowflake> IPartialMessage.ID => this.ID;

Expand Down Expand Up @@ -274,4 +279,7 @@ public interface IMessage : IPartialMessage

/// <inheritdoc/>
Optional<int> IPartialMessage.Position => this.Position;

/// <inheritdoc/>
Optional<IApplicationCommandInteractionDataResolved> IPartialMessage.Resolved => this.Resolved;
}
Original file line number Diff line number Diff line change
Expand Up @@ -119,4 +119,7 @@ public interface IPartialMessage

/// <inheritdoc cref="IMessage.Position" />
Optional<int> Position { get; }

/// <inheritdoc cref="IMessage.Resolved" />
Optional<IApplicationCommandInteractionDataResolved> Resolved { get; }
}
Original file line number Diff line number Diff line change
Expand Up @@ -63,5 +63,6 @@ public record MessageCreate
Optional<IChannel> Thread = default,
Optional<IReadOnlyList<IMessageComponent>> Components = default,
Optional<IReadOnlyList<IStickerItem>> StickerItems = default,
Optional<int> Position = default
Optional<int> Position = default,
Optional<IApplicationCommandInteractionDataResolved> Resolved = default
) : IMessageCreate;
Original file line number Diff line number Diff line change
Expand Up @@ -63,5 +63,6 @@ public record MessageUpdate
Optional<IChannel> Thread = default,
Optional<IReadOnlyList<IMessageComponent>> Components = default,
Optional<IReadOnlyList<IStickerItem>> StickerItems = default,
Optional<int> Position = default
Optional<int> Position = default,
Optional<IApplicationCommandInteractionDataResolved> Resolved = default
) : IMessageUpdate;
3 changes: 2 additions & 1 deletion Backend/Remora.Discord.API/API/Objects/Messages/Message.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,6 @@ public record Message
Optional<IChannel> Thread = default,
Optional<IReadOnlyList<IMessageComponent>> Components = default,
Optional<IReadOnlyList<IStickerItem>> StickerItems = default,
Optional<int> Position = default
Optional<int> Position = default,
Optional<IApplicationCommandInteractionDataResolved> Resolved = default
) : IMessage;
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,6 @@ public record PartialMessage
Optional<IChannel> Thread = default,
Optional<IReadOnlyList<IMessageComponent>> Components = default,
Optional<IReadOnlyList<IStickerItem>> StickerItems = default,
Optional<int> Position = default
Optional<int> Position = default,
Optional<IApplicationCommandInteractionDataResolved> Resolved = default
) : IPartialMessage;
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@
"avatar": "68b329da9893e34099c7d8ad5cb9c940",
"member": {}
}
]
],
"resolved": {}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@
"avatar": "68b329da9893e34099c7d8ad5cb9c940",
"member": {}
}
]
],
"resolved": {}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -119,5 +119,6 @@
"format_type": 1
}
],
"position": 1
"position": 1,
"resolved": {}
}

0 comments on commit c33fb31

Please sign in to comment.