Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions core/src/ops/files/query/directory_listing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ use crate::{
video_media_data,
},
infra::query::LibraryQuery,
ops::indexing::IndexScope,
};
use sea_orm::{
ColumnTrait, ConnectionTrait, DatabaseConnection, EntityTrait, JoinType, QueryFilter,
Expand Down Expand Up @@ -753,7 +754,7 @@ impl DirectoryListingQuery {
// Get library to dispatch indexer job
if let Some(library) = context.get_library(library_id).await {
// Create cache entry and get the index to share with the job
let ephemeral_index = cache.create_for_indexing(local_path.clone());
let ephemeral_index = cache.create_for_indexing(local_path.clone(), IndexScope::Current);

// Clear any stale entries from previous indexing (prevents ghost files)
let cleared = cache.clear_for_reindex(&local_path).await;
Expand Down Expand Up @@ -790,7 +791,7 @@ impl DirectoryListingQuery {
e
);
// Mark indexing as not in progress since job failed
cache.mark_indexing_complete(&local_path);
cache.mark_indexing_complete(&local_path, IndexScope::Current);
}
}
}
Expand Down
Loading
Loading