fix: allow deserialization of recent link_shared (#260)

`link_shared` events in the Slack developer sandboxes do not contain the
`source` and `unfurl_id` options anymore, as the associated
[`chat.unfurl`](https://api.slack.com/methods/chat.unfurl) API method
now mandates passing the `(channel, ts)` tuple over the
`(source, unfurl_id)` one

> Both channel and ts must be provided together, or unfurl_id and source
must be provided together.

_And_ `channel`, `ts` are marked as required arguments.

Close: #259
This commit is contained in:
Gerry Agbobada 2024-04-19 10:31:44 +02:00 committed by GitHub
parent 3fca16d346
commit d3946f6028
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View file

@ -1,6 +1,6 @@
[package]
name = "slack-morphism"
version = "2.1.1-alpha.0"
version = "2.2.0-alpha.0"
authors = ["Abdulla Abdurakhmanov <me@abdolence.dev>"]
edition = "2021"
license = "Apache-2.0"

View file

@ -205,8 +205,8 @@ pub struct SlackLinkSharedEvent {
pub is_bot_user_member: bool,
pub links: Vec<SlackLinkObject>,
pub message_ts: SlackTs,
pub source: String,
pub unfurl_id: SlackUnfurlId,
pub source: Option<String>,
pub unfurl_id: Option<SlackUnfurlId>,
pub user: SlackUserId,
}