use notify_waiters to better express intent

This commit is contained in:
OlivierDehaene 2022-12-05 10:09:37 +01:00 committed by GitHub
parent aaf38e5978
commit cb89376932
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -70,7 +70,7 @@ impl Batcher {
// Notify the background task that we have a new entry in the database that needs // Notify the background task that we have a new entry in the database that needs
// to be batched // to be batched
self.shared.batching_task.notify_one(); self.shared.batching_task.notify_waiters();
// Await on the response from the background task // Await on the response from the background task
// We can safely unwrap as the background task will never drop the sender // We can safely unwrap as the background task will never drop the sender