1
0
mirror of https://github.com/jhillyerd/inbucket.git synced 2025-12-18 01:57:02 +00:00

Package reorganization part 2

End goal is to simplify build
This commit is contained in:
James Hillyerd
2012-10-22 15:48:55 -07:00
parent 4e5c0ce4d8
commit 7215c041dc
11 changed files with 60 additions and 65 deletions

View File

@@ -7,7 +7,7 @@ import (
"fmt"
"github.com/gorilla/mux"
"github.com/gorilla/sessions"
"github.com/jhillyerd/inbucket"
"github.com/jhillyerd/inbucket/config"
"github.com/jhillyerd/inbucket/log"
"net/http"
"thegoods.biz/httpbuf"
@@ -20,7 +20,7 @@ var Router *mux.Router
var sessionStore sessions.Store
func setupRoutes(cfg inbucket.WebConfig) {
func setupRoutes(cfg config.WebConfig) {
Router = mux.NewRouter()
log.Info("Theme templates mapped to '%v'", cfg.TemplateDir)
log.Info("Theme static content mapped to '%v'", cfg.PublicDir)
@@ -42,7 +42,7 @@ func setupRoutes(cfg inbucket.WebConfig) {
// Start() the web server
func Start() {
cfg := inbucket.GetWebConfig()
cfg := config.GetWebConfig()
setupRoutes(cfg)
sessionStore = sessions.NewCookieStore([]byte("something-very-secret"))