compile tags regex once
This commit is contained in:
parent
f599483aab
commit
7686dfa474
5 changed files with 27 additions and 10 deletions
|
|
@ -2,7 +2,10 @@
|
|||
|
||||
package core
|
||||
|
||||
import "html/template"
|
||||
import (
|
||||
"html/template"
|
||||
"regexp"
|
||||
)
|
||||
|
||||
type User struct {
|
||||
Username string
|
||||
|
|
@ -25,6 +28,11 @@ type Tag struct {
|
|||
Regex string
|
||||
}
|
||||
|
||||
type RTag struct {
|
||||
Name string
|
||||
Regex *regexp.Regexp
|
||||
}
|
||||
|
||||
type Path struct {
|
||||
Name string
|
||||
Abs string
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue