Release Notes: - N/A
Unified · Split
| @@ -501,8 +501,10 @@ impl Database { · 500 unmodified lines | ||
| 501 | 501 | |
| 502 | 502 | /// Returns all channels for the user with the given ID. |
| 503 | 503 | pub async fn get_channels_for_user(&self, user_id: UserId) -> Result<ChannelsForUser> { |
| 504 | − self.transaction(|tx| async move { self.get_user_channels(user_id, None, true, &tx).await }) | |
| 505 | − .await | |
| 504 | + self.weak_transaction( | |
| 505 | + |tx| async move { self.get_user_channels(user_id, None, true, &tx).await }, | |
| 506 | + ) | |
| 507 | + .await | |
| 506 | 508 | } |
| 507 | 509 | |
| 508 | 510 | /// Returns all channels for the user with the given ID that are descendants |
| @@ -15,7 +15,7 @@ impl Database { · 14 unmodified lines | ||
| 15 | 15 | user_b_busy: bool, |
| 16 | 16 | } |
| 17 | 17 | |
| 18 | − self.transaction(|tx| async move { | |
| 18 | + self.weak_transaction(|tx| async move { | |
| 19 | 19 | let user_a_participant = Alias::new("user_a_participant"); |
| 20 | 20 | let user_b_participant = Alias::new("user_b_participant"); |
| 21 | 21 | let mut db_contacts = contact::Entity::find() |
| @@ -91,7 +91,7 @@ impl Database { · 69 unmodified lines | ||
| 91 | 91 | |
| 92 | 92 | /// Returns whether the given user is a busy (on a call). |
| 93 | 93 | pub async fn is_user_busy(&self, user_id: UserId) -> Result<bool> { |
| 94 | − self.transaction(|tx| async move { | |
| 94 | + self.weak_transaction(|tx| async move { | |
| 95 | 95 | let participant = room_participant::Entity::find() |
| 96 | 96 | .filter(room_participant::Column::UserId.eq(user_id)) |
| 97 | 97 | .one(&*tx) |
| @@ -80,7 +80,7 @@ impl Database { · 79 unmodified lines | ||
| 80 | 80 | &self, |
| 81 | 81 | user_id: UserId, |
| 82 | 82 | ) -> Result<Option<proto::IncomingCall>> { |
| 83 | − self.transaction(|tx| async move { | |
| 83 | + self.weak_transaction(|tx| async move { | |
| 84 | 84 | let pending_participant = room_participant::Entity::find() |
| 85 | 85 | .filter( |
| 86 | 86 | room_participant::Column::UserId |