Skip to content

Commit

Permalink
Fix i18n language code validation to include -
Browse files Browse the repository at this point in the history
  • Loading branch information
knadh committed Aug 28, 2021
1 parent 3847c67 commit 00275df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ type pagination struct {

var (
reUUID = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
reLangCode = regexp.MustCompile("[^a-zA-Z_0-9]")
reLangCode = regexp.MustCompile("[^a-zA-Z_0-9\\-]")
)

// registerHandlers registers HTTP handlers.
Expand Down

0 comments on commit 00275df

Please sign in to comment.