MCPcopy Index your code
hub / github.com/callumalpass/tasknotes / requireTask

Method requireTask

src/api/TaskNotesAPI.ts:2655–2665  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

2653 }
2654
2655 private async requireTask(path: string): Promise<TaskInfo> {
2656 const normalizedPath = this.normalizeTaskPath(path);
2657 const task = await this.plugin.cacheManager.getTaskInfo(normalizedPath);
2658 if (!task) {
2659 throw new TaskNotesApiError("task_not_found", `Task not found: ${normalizedPath}`, {
2660 status: 404,
2661 details: { path: normalizedPath },
2662 });
2663 }
2664 return task;
2665 }
2666
2667 private requireTaskFile(path: string): TFile {
2668 const file = this.plugin.app.vault.getAbstractFileByPath(path);

Callers 15

getTaskTimeDataMethod · 0.95
populateTaskMenuMethod · 0.95
buildTaskContextMenuMethod · 0.95
getParentTasksMethod · 0.95
getSubtasksMethod · 0.95
getTaskDependenciesMethod · 0.95
getBlockingTasksMethod · 0.95
getTaskRelationshipsMethod · 0.95
updateTaskMethod · 0.95
completeTaskMethod · 0.95
rescheduleTaskMethod · 0.95
archiveTaskMethod · 0.95

Calls 2

normalizeTaskPathMethod · 0.95
getTaskInfoMethod · 0.65

Tested by

no test coverage detected