mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-04 12:27:13 +02:00
makes the updates getters smoother to uses
This commit is contained in:
parent
7879189c6b
commit
72b2e68de4
2 changed files with 17 additions and 26 deletions
|
@ -169,21 +169,16 @@ impl IndexScheduler {
|
|||
|
||||
if let Some(indexes) = task.indexes() {
|
||||
for index in indexes {
|
||||
self.update_index(&mut wtxn, index, |mut bitmap| {
|
||||
bitmap.insert(task_id);
|
||||
bitmap
|
||||
})?;
|
||||
self.update_index(&mut wtxn, index, |bitmap| drop(bitmap.insert(task_id)))?;
|
||||
}
|
||||
}
|
||||
|
||||
self.update_status(&mut wtxn, Status::Enqueued, |mut bitmap| {
|
||||
self.update_status(&mut wtxn, Status::Enqueued, |bitmap| {
|
||||
bitmap.insert(task_id);
|
||||
bitmap
|
||||
})?;
|
||||
|
||||
self.update_kind(&mut wtxn, task.kind.as_kind(), |mut bitmap| {
|
||||
bitmap.insert(task_id);
|
||||
bitmap
|
||||
self.update_kind(&mut wtxn, task.kind.as_kind(), |bitmap| {
|
||||
(bitmap.insert(task_id));
|
||||
})?;
|
||||
|
||||
// we persist the file in last to be sure everything before was applied successfuly
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue