Skip to content
Open
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
14 changes: 7 additions & 7 deletions src/filter/ztf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -712,6 +712,13 @@ impl FilterWorker for ZtfFilterWorker {
)
.await?;

// If we have output documents, we need to process them
// and create filter results for each document (which contain annotations)
// however, if the array is empty, there's nothing to do
if out_documents.is_empty() {
continue;
}

info!(
"{}/{} ZTF alerts with programid {} passed filter {}",
out_documents.len(),
Expand All @@ -720,13 +727,6 @@ impl FilterWorker for ZtfFilterWorker {
filter.id,
);

// If we have output documents, we need to process them
// and create filter results for each document (which contain annotations)
// however, if the array is empty, there's nothing to do
if out_documents.is_empty() {
continue;
}

let now_ts = chrono::Utc::now().timestamp_millis() as f64;

for doc in out_documents {
Expand Down
Loading