Skip to content
This repository has been archived by the owner on Oct 21, 2019. It is now read-only.

Remove completely broken NameRegex #89

Merged
merged 1 commit into from
Jul 20, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 0 additions & 2 deletions cmd/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ var (
AnyRegex = regexp.MustCompile(".+")
// AlphaRegex matches words containing only letters
AlphaRegex = regexp.MustCompile("[a-zA-Z]")
// NameRegex matches people's names
NameRegex = regexp.MustCompile("^[a-zA-Z'-]+$")
// EmailRegex matches email addresses
EmailRegex = regexp.MustCompile("[a-zA-Z0-9._+]+@[a-zA-Z0-9._]+")
)
Expand Down
2 changes: 1 addition & 1 deletion plugins/core/add_team.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func NewAddTeamCmd(ch cmd.CommandHandler) *cmd.Command {
"github": &cmd.Option{
Key: "github",
HelpText: "the name of the team to create on GitHub",
Format: cmd.NameRegex,
Format: cmd.AnyRegex,
Required: false,
},
},
Expand Down
2 changes: 1 addition & 1 deletion plugins/core/edit_user.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ func NewEditUserCmd(ch cmd.CommandHandler) *cmd.Command {
"name": &cmd.Option{
Key: "name",
HelpText: "user's full name",
Format: cmd.NameRegex,
Format: cmd.AnyRegex,
Required: false,
},
"email": &cmd.Option{
Expand Down
2 changes: 1 addition & 1 deletion plugins/core/set.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func NewSetCmd(ch cmd.CommandHandler) *cmd.Command {
"name": &cmd.Option{
Key: "name",
HelpText: "your full name",
Format: cmd.NameRegex,
Format: cmd.AnyRegex,
Required: false,
},
"email": &cmd.Option{
Expand Down