Refactor delete handling and improve logging in event processing

- Updated the HandleDelete function to allow delete events to be stored even if no valid targets are found, enhancing flexibility in event management.
- Improved logging to provide clearer insights when no deletions are processed, ensuring that issues are logged without blocking event acceptance.
- Refactored SHA256 validation tests and adjusted expected values to ensure accuracy in hash comparisons.
- Enhanced various test cases to improve coverage and reliability across the application.
This commit is contained in:
2025-11-05 08:48:21 +00:00
parent 9d13811f6b
commit f35440ed1d
10 changed files with 51 additions and 34 deletions

View File

@@ -17,7 +17,7 @@ const (
maxRangeSize = 10 * 1024 * 1024 // 10MB max range request
)
var sha256Regex = regexp.MustCompile(`^[a-fA-F0-9]{64}`)
var sha256Regex = regexp.MustCompile(`[a-fA-F0-9]{64}`)
// CalculateSHA256 calculates the SHA256 hash of data
func CalculateSHA256(data []byte) []byte {