(ownerWorkspaceId: string, id: string)
| 199 | } |
| 200 | |
| 201 | async get(ownerWorkspaceId: string, id: string): Promise<BashMonitorWakeRecord | null> { |
| 202 | let raw: string; |
| 203 | try { |
| 204 | raw = await fsPromises.readFile(this.file(ownerWorkspaceId, id), "utf-8"); |
| 205 | } catch (error) { |
| 206 | if (isErrnoWithCode(error, "ENOENT")) return null; |
| 207 | throw error; |
| 208 | } |
| 209 | return this.parse(raw); |
| 210 | } |
| 211 | |
| 212 | async listPending(ownerWorkspaceId: string): Promise<BashMonitorWakeRecord[]> { |
| 213 | const dir = this.dir(ownerWorkspaceId); |
no test coverage detected