(file: string, sha: string)
| 22 | } |
| 23 | |
| 24 | export async function verifySHA(file: string, sha: string): Promise<boolean> { |
| 25 | const hash = await calculateSHA(file); |
| 26 | return hash.toLocaleLowerCase() === sha.toLocaleLowerCase(); |
| 27 | } |
| 28 | |
| 29 | // calculateSHA('~/comfyui/models/loras/xx.safetensors.tmp') |
| 30 | // .then((hash) => { |
no test coverage detected