portfolio/api/service/validate/validateUser.go
2024-05-15 15:49:39 +02:00

14 lines
173 B
Go

package validate
import (
"portfolio_api/database/ent"
)
func UserIsValid(u *ent.User) bool {
if len(u.Name) > 0 &&
len(u.Role) > 0 {
return true
}
return false
}