make to_ids const in some places, and simplify returns from create_or_lookup_adhoc_group

This commit is contained in:
holger krekel
2019-12-04 13:25:28 +01:00
parent 56fc5a19ae
commit cb9e0dc5c8
3 changed files with 74 additions and 73 deletions

View File

@@ -579,6 +579,10 @@ pub fn unblock(context: &Context, chat_id: u32) {
}
pub fn set_blocking(context: &Context, chat_id: u32, new_blocking: Blocked) -> bool {
if chat_id == 0 {
warn!(context, "ignoring setting of Block-status for chat_id=0");
return false;
}
sql::execute(
context,
&context.sql,