This commit is contained in:
Evan Jarrett
2025-11-24 13:57:32 -06:00
parent 88df0c4ae5
commit 08b8bcf295
+3 -4
View File
@@ -133,10 +133,9 @@ func (vc *validationCache) getOrFetch(ctx context.Context, cacheKey string, fetc
}
}
// Mark as in-flight and create done channel if needed
if entry.done == nil {
entry.done = make(chan struct{})
}
// Mark as in-flight and create fresh done channel for this fetch
// IMPORTANT: Always create a new channel - a closed channel is not nil
entry.done = make(chan struct{})
entry.inFlight = true
done := entry.done
entry.mu.Unlock()