Updated reply to include document name.
Some checks failed
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 0s

This commit is contained in:
2026-02-14 13:45:49 -05:00
parent 1f82c07565
commit 903158b72a
4 changed files with 43 additions and 93 deletions

View File

@@ -537,11 +537,17 @@ impl DocumentFile {
};
route_action.insert(route_id.clone(), path_action.doc_function());
}
let mut doc = DocumentFile::new(queue.clone(), rx, docdef, route_action, name_id.clone());
let mut doc = DocumentFile::new(
queue.clone(),
rx,
docdef.clone(),
route_action,
name_id.clone(),
);
spawn(move || {
doc.listen();
});
let reply = msg.response(Reply::new());
let reply = msg.response(Reply::new(names[0].clone()));
queue.send(reply.clone());
}
@@ -555,7 +561,9 @@ impl DocumentFile {
DocFuncType::Add => self.add_document(&msg),
DocFuncType::Delete => self.delete(&msg),
DocFuncType::Query => self.query(&msg),
DocFuncType::Show => self.queue.send(msg.response(Reply::new())),
DocFuncType::Show => self.queue.send(
msg.response(Reply::new(self.docdef.get_document_names()[0].clone())),
),
DocFuncType::Update => self.update(&msg),
DocFuncType::ExistingQuery(action) => self.existing_query(&msg, action),
DocFuncType::Trigger(action) => self.trigger(&msg, action),