mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-08-05 15:20:30 +08:00
Go: fix warnings (#17738)
Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
@@ -126,7 +126,7 @@ def reset_document_for_reparse(doc, tenant_id, parser_id=None, pipeline_id=None)
|
||||
# Update document
|
||||
e = DocumentService.update_by_id(doc.id, update_fields)
|
||||
if not e:
|
||||
return get_error_data_result(message="Document not found!")
|
||||
return get_error_data_result(message="document not found")
|
||||
|
||||
# Update document statistics before deleting all document rows. Pipeline
|
||||
# compilation rows may exist even when token_num is zero, so the doc-store
|
||||
@@ -141,9 +141,9 @@ def reset_document_for_reparse(doc, tenant_id, parser_id=None, pipeline_id=None)
|
||||
doc.process_duration * -1,
|
||||
)
|
||||
except LookupError:
|
||||
return get_error_data_result(message="Document not found!")
|
||||
return get_error_data_result(message="document not found")
|
||||
if not e:
|
||||
return get_error_data_result(message="Document not found!")
|
||||
return get_error_data_result(message="document not found")
|
||||
settings.docStoreConn.delete({"doc_id": doc.id}, search.index_name(tenant_id), doc.kb_id)
|
||||
|
||||
# Delete chunk images
|
||||
|
||||
Reference in New Issue
Block a user