mirror of
https://github.com/teloxide/teloxide.git
synced 2024-12-22 22:46:39 +01:00
remove TargetMessage as ChatOrInlineMessage reexport as it couldn't be deprecated
Also rename `TargetMessage::{Chat => Common}` variant. (anyway `ChatOrInlineMessage`/`TargetMessage` refactoring is not backward compatible)
This commit is contained in:
parent
851e4c6bc6
commit
02400b18ab
1 changed files with 1 additions and 4 deletions
|
@ -6,13 +6,10 @@ use serde::{Deserialize, Serialize};
|
|||
#[derive(Clone, Debug, Eq, Hash, PartialEq, Serialize, Deserialize)]
|
||||
#[serde(untagged)]
|
||||
pub enum TargetMessage {
|
||||
Chat { chat_id: ChatId, message_id: i32 },
|
||||
Common { chat_id: ChatId, message_id: i32 },
|
||||
Inline { inline_message_id: String },
|
||||
}
|
||||
|
||||
#[deprecated = "Was renamed to `TargetMessage`, please use renamed version"]
|
||||
pub use TargetMessage as ChatOrInlineMessage;
|
||||
|
||||
impl From<String> for TargetMessage {
|
||||
fn from(inline_message_id: String) -> Self {
|
||||
Self::Inline { inline_message_id }
|
||||
|
|
Loading…
Reference in a new issue