1
0
Fork 0
forked from TWS/kalkutago

Compare commits

...

2 commits

Author SHA1 Message Date
D. Scott Boggs 033f2a561b Nit 2023-08-26 14:51:14 -04:00
D. Scott Boggs 019ccda845 Rename variable 2023-08-26 14:50:05 -04:00
2 changed files with 3 additions and 2 deletions

View file

@ -32,7 +32,7 @@ async fn get_track_check_user(
track_id: i32,
user: &users::Model,
) -> Result<Json<tracks::Model>, Either<Status, api::ErrorResponder>> {
if let Some(Some(user)) = user
if let Some(Some(track)) = user
.find_related(Tracks)
.filter(tracks::Column::Id.eq(track_id))
.one(db)
@ -40,7 +40,7 @@ async fn get_track_check_user(
.transpose()
.map(|it| it.ok())
{
Ok(Json(user))
Ok(Json(track))
} else {
Err(Left(Status::NotFound))
}

View file

@ -95,6 +95,7 @@ impl Update {
if receiver_count > 0 {
trace!(receiver_count = receiver_count, update = as_serde!(self); "sending update");
let count = tx.send(self.clone())?;
trace!(count = count; "update sent");
} else {
trace!("no update receivers, skipping message");
}