Skip to content

Commit

Permalink
Merge pull request #373 from Quasilyte/regexpMust
Browse files Browse the repository at this point in the history
replace regexp.Compile with regexp.MustCompile
  • Loading branch information
chris-ramon authored Jul 28, 2018
2 parents 4620584 + 1e154ea commit 8bad5f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion definition.go
Original file line number Diff line number Diff line change
Expand Up @@ -1281,7 +1281,7 @@ func (gl *NonNull) Error() error {
return gl.err
}

var NameRegExp, _ = regexp.Compile("^[_a-zA-Z][_a-zA-Z0-9]*$")
var NameRegExp = regexp.MustCompile("^[_a-zA-Z][_a-zA-Z0-9]*$")

func assertValidName(name string) error {
return invariantf(
Expand Down

0 comments on commit 8bad5f4

Please sign in to comment.