fix: typo in RandomAcc() comment (#11440)

Fixes a typo in the function comment for RandomAcc() in `types/simulation/account.go`.
This commit is contained in:
Alex Johnson 2022-03-26 20:18:31 -04:00 committed by GitHub
parent cc0b9dfe0a
commit 73c9f42fc0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -25,8 +25,7 @@ func (acc Account) Equals(acc2 Account) bool {
return acc.Address.Equals(acc2.Address)
}
// RandomAcc picks and returns a random account from an array and returs its
// position in the array.
// RandomAcc picks and returns a random account and its index from an array.
func RandomAcc(r *rand.Rand, accs []Account) (Account, int) {
idx := r.Intn(len(accs))
return accs[idx], idx