MCPcopy Index your code
hub / github.com/gotify/server / generateRandomString

Function generateRandomString

auth/token.go:61–68  ·  view source on GitHub ↗
(length int)

Source from the content-addressed store, hash-verified

59}
60
61func generateRandomString(length int) string {
62 res := make([]byte, length)
63 for i := range res {
64 index := randIntn(len(tokenCharacters))
65 res[i] = tokenCharacters[index]
66 }
67 return string(res)
68}
69
70func init() {
71 randIntn(2)

Callers 2

GenerateImageNameFunction · 0.85
generateRandomTokenFunction · 0.85

Calls 1

randIntnFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…