MCPcopy Index your code
hub / github.com/omkarcloud/botasaurus / getTask

Method getTask

js/botasaurus-server-js/src/task-helper.ts:824–839  ·  view source on GitHub ↗
(taskId: number, inStatus?: string[])

Source from the content-addressed store, hash-verified

822 }
823
824 static getTask(taskId: number, inStatus?: string[]): Promise<Task> {
825 return new Promise((resolve, reject) => {
826 const query: any = { id: taskId };
827 if (inStatus) {
828 query.status = { $in: inStatus };
829 }
830
831 db.findOne(query, (err: Error | null, task: any) => {
832 if (err) {
833 reject(err);
834 } else {
835 resolve(createTask(task));
836 }
837 });
838 });
839 }
840
841 static getTaskWithEntities(
842 taskId: number,

Callers 10

fetchTaskResultFunction · 0.45
getTaskFromDbFunction · 0.45
refetchTasksFunction · 0.45
deleteTaskFunction · 0.45
abortTaskFunction · 0.45
retrieveTaskResultsFunction · 0.45
getTaskErrorFunction · 0.45

Calls 1

createTaskFunction · 0.90

Tested by

no test coverage detected