Don't assign var

This commit is contained in:
Aaron Bieber 2021-12-09 05:48:34 -07:00
parent 4fdac0116f
commit f9de42e801

View File

@ -63,9 +63,9 @@ type userHandler struct {
type userHandlers []userHandler
func (u userHandlers) find(name string) *userHandler {
for _, usr := range u {
if usr.name == name {
return &usr
for i := range u {
if u[i].name == name {
return &u[i]
}
}
return nil