Skip to content

Commit

Permalink
Remove some redundancy in wellParen
Browse files Browse the repository at this point in the history
  • Loading branch information
mvdan committed May 2, 2015
1 parent d8e2344 commit 0193237
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xurls.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const (
iri = `[` + iriChar + `]([` + iriChar + `\-]*[` + iriChar + `])?`
domain = `(` + iri + `\.)+`
hostName = `(` + domain + gtld + `|` + ipAddr + `)`
wellParen = `([` + pathChar + `]*(\([` + pathChar + `]*\))+)+`
wellParen = `([` + pathChar + `]*\([` + pathChar + `]*\))`
pathCont = `(` + wellParen + `|[` + pathChar + `]*[` + endChar + `])`
path = `(/` + pathCont + `?|\b|$)`
webURL = hostName + `(:[0-9]*)?` + path
Expand Down

0 comments on commit 0193237

Please sign in to comment.