(taskListId: string)
| 113 | } |
| 114 | |
| 115 | async function readHighWaterMark(taskListId: string): Promise<number> { |
| 116 | const path = getHighWaterMarkPath(taskListId) |
| 117 | try { |
| 118 | const content = (await readFile(path, 'utf-8')).trim() |
| 119 | const value = parseInt(content, 10) |
| 120 | return isNaN(value) ? 0 : value |
| 121 | } catch { |
| 122 | return 0 |
| 123 | } |
| 124 | } |
| 125 | |
| 126 | async function writeHighWaterMark( |
| 127 | taskListId: string, |
no test coverage detected