(
directory: OPFSDirectoryHandle,
filename: string,
)
| 498 | } |
| 499 | |
| 500 | private async removeEntryIfExists( |
| 501 | directory: OPFSDirectoryHandle, |
| 502 | filename: string, |
| 503 | ): Promise<void> { |
| 504 | try { |
| 505 | await directory.removeEntry(filename); |
| 506 | } catch (err) { |
| 507 | if (OPFSStore.isNotFoundError(err)) { |
| 508 | // Delete is intentionally idempotent for missing entries |
| 509 | return; |
| 510 | } |
| 511 | throw err; |
| 512 | } |
| 513 | } |
| 514 | |
| 515 | private async hashUrl(url: string): Promise<string> { |
| 516 | const textEncoder = new TextEncoder(); |
no test coverage detected