Remove Dispatcher::setup_ctrlc_handler

This commit is contained in:
Maybe Waffle 2024-02-13 20:46:28 +01:00
parent 2e8b4cfa19
commit d7b954b1c6
2 changed files with 1 additions and 9 deletions

View file

@ -133,6 +133,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- `ChatMemberStatus::is_present` (use `ChatMemberKind::is_present` instead)
- `InlineKeyboardButton::{text, kind}`
`teloxide::dispatching::{update_listeners, repls}` (use `reloxide::{update_listeners, repls}` instead)
- `Dispatcher::setup_ctrlc_handler` (use `enable_ctrlc_handler` on the builder instead)
[pr954]: https://github.com/teloxide/teloxide/pull/954
[pr1013]: https://github.com/teloxide/teloxide/pull/1013

View file

@ -482,15 +482,6 @@ where
}
}
/// Setups the `^C` handler in order to call [`ShutdownToken::shutdown`]
/// when pressed.
#[cfg(feature = "ctrlc_handler")]
#[deprecated(since = "0.10.0", note = "use `enable_ctrlc_handler` on builder instead")]
pub fn setup_ctrlc_handler(&mut self) -> &mut Self {
self.setup_ctrlc_handler_inner();
self
}
/// Returns a shutdown token, which can later be used to
/// [`ShutdownToken::shutdown`].
pub fn shutdown_token(&self) -> ShutdownToken {