( ...fields: (string | undefined | null)[] )
| 57 | * ``` |
| 58 | */ |
| 59 | export function generateFindingHash( |
| 60 | ...fields: (string | undefined | null)[] |
| 61 | ): string { |
| 62 | const normalized = fields |
| 63 | .map((f) => (f ?? '').toLowerCase().trim()) |
| 64 | .join('|'); |
| 65 | return createHash('sha256').update(normalized).digest('hex').slice(0, 16); |
| 66 | } |
no test coverage detected