Explicit API for creating chats with blocked status

This introduces the explicit ChatIdBlocked struct to more explicitly
create a chat with a blocked status.  It also adds a common shortcut
to ChatId itself which is more natural to use in many cases.
This commit is contained in:
Floris Bruynooghe
2021-03-04 19:58:37 +01:00
parent 99d9773b75
commit be413b20f1
7 changed files with 186 additions and 116 deletions

View File

@@ -126,7 +126,7 @@ where
}
}
impl<T: Default, E: std::fmt::Display> LogExt<T, E> for Result<T, E> {
impl<T, E: std::fmt::Display> LogExt<T, E> for Result<T, E> {
#[track_caller]
fn log_err_inner(self, context: &Context, msg: Option<&str>) -> Result<T, E> {
if let Err(e) = &self {