Skip to content

Commit

Permalink
add /uses
Browse files Browse the repository at this point in the history
  • Loading branch information
quantonganh committed Mar 1, 2024
1 parent 3b61b56 commit 071ca5d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions http/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,10 @@ func NewServer(config *blog.Config, posts []*blog.Post) (*Server, error) {
s.newRoute("/{year:20[0-9][0-9]}/{month:0[1-9]|1[012]}/{day:0[1-9]|[12][0-9]|3[01]}", s.postsByDateHandler)
s.newRoute("/{year:20[0-9][0-9]}/{month:0[1-9]|1[012]}", s.postsByMonthHandler)
s.newRoute("/{year:20[0-9][0-9]}", s.postsByYearHandler)
s.newRoute("/about", s.postHandler(config.Posts.Dir))
s.newRoute("/resume", s.postHandler(config.Posts.Dir))
s.newRoute("/projects", s.postHandler(config.Posts.Dir))
s.router.PathPrefix("/about").HandlerFunc(s.Error(s.postHandler(config.Posts.Dir)))
s.router.PathPrefix("/resume").HandlerFunc(s.Error(s.postHandler(config.Posts.Dir)))
s.router.PathPrefix("/projects").HandlerFunc(s.Error(s.postHandler(config.Posts.Dir)))
s.router.PathPrefix("/uses").HandlerFunc(s.Error(s.postHandler(config.Posts.Dir)))
s.newRoute("/photos", s.photosHandler)
s.newRoute("/categories/{categoryName}", s.categoryHandler)
s.newRoute("/tags", s.tagsHandler)
Expand Down

0 comments on commit 071ca5d

Please sign in to comment.