MCPcopy
hub / github.com/callumalpass/tasknotes / constructor

Method constructor

src/services/TaskService.ts:99–118  ·  view source on GitHub ↗
(private plugin: TaskNotesPlugin)

Source from the content-addressed store, hash-verified

97 private readonly taskUpdateService: TaskUpdateService;
98
99 constructor(private plugin: TaskNotesPlugin) {
100 this.taskCreationService = new TaskCreationService({
101 runtime: this.plugin,
102 webhookNotifier: this.webhookNotifier,
103 applyTaskCreationDefaults: (taskData) =>
104 Promise.resolve(applyTaskCreationDefaultsToData(taskData, this.plugin.settings)),
105 applyTemplate: (taskData) => this.applyTemplate(taskData),
106 processFolderTemplate: (folderTemplate, taskData, date) =>
107 this.processFolderTemplate(folderTemplate, taskData, date),
108 sanitizeTitleForFilename: sanitizeTaskTitleForFilename,
109 sanitizeTitleForStorage: sanitizeTaskTitleForStorage,
110 });
111 this.taskUpdateService = new TaskUpdateService({
112 runtime: this.plugin,
113 webhookNotifier: this.webhookNotifier,
114 autoArchiveService: this.autoArchiveService,
115 updateCompletedDateInFrontmatter: (frontmatter, newStatus, isRecurring) =>
116 this.updateCompletedDateInFrontmatter(frontmatter, newStatus, isRecurring),
117 });
118 }
119
120 private hasGoogleCalendarLinks(task: TaskInfo): boolean {
121 return Boolean(task.googleCalendarEventId || task.googleCalendarExceptionEventId);

Callers

nothing calls this directly

Calls 4

applyTemplateMethod · 0.95
processFolderTemplateMethod · 0.95
resolveMethod · 0.80

Tested by

no test coverage detected