This commit is contained in:
Septias
2024-11-10 17:37:02 +01:00
parent 092b6e96ea
commit 9f1eb45acd
2 changed files with 6 additions and 2 deletions

View File

@@ -2521,7 +2521,9 @@ pub unsafe extern "C" fn dc_is_sending_locations_to_chat(
}; };
block_on(async { block_on(async {
location::is_sending_locations_to_chat(ctx, chat_id).await.map(|res| res as u8) location::is_sending_locations_to_chat(ctx, chat_id)
.await
.map(|res| res as u8)
}) })
.unwrap_or_log_default(ctx, "Failed dc_is_sending_locations_to_chat()") as libc::c_int .unwrap_or_log_default(ctx, "Failed dc_is_sending_locations_to_chat()") as libc::c_int
} }

View File

@@ -629,7 +629,9 @@ pub async fn cmdline(context: Context, line: &str, chat_id: &mut ChatId) -> Resu
); );
} }
} }
if location::is_sending_locations_to_chat(&context, None).await? != location::LocationSendingStatus::Disabled { if location::is_sending_locations_to_chat(&context, None).await?
!= location::LocationSendingStatus::Disabled
{
println!("Location streaming enabled."); println!("Location streaming enabled.");
} }
println!("{cnt} chats"); println!("{cnt} chats");