You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
func (ss *saltStoreImpl) saltAndHash(type string, value string) string {
if len(value) == 0 {
return ""
}
salt := ""
// var typeToSalt map[string]string
if ss.typeToSalt != nil {
// If the salts are defined we use the salt for the key if exists and non-empty.
if s, ok := ss.typeToSalt[type]; ok {
salt = s
}
}
if len(salt) == 0 {
return Hash(value)
}
return Hash(fmt.Sprintf("%s%s", value, salt)) // <--- panic line
}
extra info, this function is run within a goroutine a few stacks deep
What did you expect to see?
no panics
What did you see instead?
invalid memory address or nil pointer dereference panic
Stacktrace (github.com/askscio/scio/go/** is our internal codebase):
Go version
go version go1.17.13 darwin/amd64
What operating system and processor architecture are you using (
go env
)?What did you do?
extra info, this function is run within a goroutine a few stacks deep
What did you expect to see?
no panics
What did you see instead?
invalid memory address or nil pointer dereference panic
Stacktrace (
github.com/askscio/scio/go/**
is our internal codebase):The text was updated successfully, but these errors were encountered: