validator

package
v0.0.0-...-4c3d7af Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 6, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrInvalidUsernameFormat gives error message when user attempts to join a lobby when is already in lobby
	ErrInvalidUsernameFormat = errors.New("username is not valid (example valid: 2 < length < 20 and must be A-z 0-9 - _)")

	// ErrNotValidEmail gives error message when user provides non-valid email
	ErrNotValidEmail = errors.New("email provided is not valid")
)

Functions

func IsEmail

func IsEmail(email string) error

func Username

func Username(input string) error

Username must contain alphanumerics, dashes, or unserscores and is from 2 to 20 characters long

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL