schmorrison / Zoho

Golang API for Zoho services
MIT License
35 stars 34 forks source link

rand not used properly #16

Closed vazha closed 5 years ago

vazha commented 5 years ago

rand not used properly in crm.go id = append(id, keyspace[rand.Intn(len(keyspace))]) always produced the same sequence.

Can be used as follow: s := rand.NewSource(time.Now().UnixNano()) r := rand.New(s) id = append(id, keyspace[r.Intn(len(keyspace))])

schmorrison commented 5 years ago

Ok thanks. Wanna make a PR?

Best regards,

schmorrison

schmorrison commented 5 years ago

Closed by #17