feat(sdk): Remove NotificationSettings::subscribe_to_changes.

This patch removes `NotificationSettings::subscribe_to_changes` because
it's not used anywhere in our code except in tests. It is indeed part of
the public API but I'm not aware of anyone using it for the moment. It
only adds complexity in the code.
This commit is contained in:
Ivan Enderlin
2024-08-14 17:02:01 +02:00
parent b497577717
commit 4e291205d5
2 changed files with 5 additions and 56 deletions

View File

@@ -582,8 +582,6 @@ async fn test_room_notification_count() -> Result<()> {
// Now Alice is only interesting in mentions of their name.
let settings = alice.notification_settings().await;
let mut settings_changes = settings.subscribe_to_changes();
tracing::warn!("Updating room notification mode to mentions and keywords only...");
settings
.set_room_notification_mode(
@@ -594,7 +592,7 @@ async fn test_room_notification_count() -> Result<()> {
tracing::warn!("Done!");
// Wait for remote echo.
timeout(Duration::from_secs(3), settings_changes.recv())
tokio::time::sleep(Duration::from_secs(3))
.await
.expect("timeout when waiting for settings update")
.expect("should've received echo after updating settings");