Skip to content

Commit

Permalink
Merge pull request #182 from teloxide/deprecate_chat_id
Browse files Browse the repository at this point in the history
Deprecate `Message::chat_id`
  • Loading branch information
WaffleLapkin committed Feb 17, 2022
2 parents 016763c + 6bf2042 commit b079722
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## unreleased

### Deprecated

- `Message::chat_id` use `.chat.id` field instead ([#182][pr182])

[pr182]: https://github.com/teloxide/teloxide-core/pull/182

### Fixed

- Serialization of `SendPoll::type_` (it's now possible to send quiz polls) ([#181][pr181])
Expand Down
1 change: 1 addition & 0 deletions src/types/message.rs
Original file line number Diff line number Diff line change
Expand Up @@ -557,6 +557,7 @@ mod getters {
}
}

#[deprecated(since = "0.4.2", note = "use `.chat.id` field instead")]
pub fn chat_id(&self) -> i64 {
self.chat.id
}
Expand Down

0 comments on commit b079722

Please sign in to comment.