🎨 Format files

This commit is contained in:
aykhans committed 2025-04-03 05:01:22 +04:00
1 parent e80ae9ab24
commit 42d5617e3f
16 files changed
+55 -49

No files matched your search

+1 -5
View File
@@ -6,9 +6,5 @@ func IsNilOrZero[T comparable](value *T) bool {
}
var zero T
if *value == zero {
return true
}
return false
return *value == zero
}
+3 -3
View File
@@ -20,9 +20,9 @@ func Flatten[T any](nested [][]*T) []*T {
// The returned function isn't thread-safe and should be used in a single-threaded context.
func RandomValueCycle[Value any](values []Value, localRand *rand.Rand) func() Value {
var (
clientsCount int = len(values)
currentIndex int = localRand.Intn(clientsCount)
stopIndex int = currentIndex
clientsCount = len(values)
currentIndex = localRand.Intn(clientsCount)
stopIndex = currentIndex
)
return func() Value {