diff options
| author | lost+skunk <[email protected]> | 2024-07-13 23:55:28 +0300 |
|---|---|---|
| committer | lost+skunk <[email protected]> | 2024-07-13 23:55:28 +0300 |
| commit | e02174cb710e6d6abd642f03e64ce91bbac38130 (patch) | |
| tree | 691795941b1fda1e37df100b7b70c2134350e274 /app/router.go | |
| parent | 4b3bf2c6a063f5702cb35626b595d11bd6630068 (diff) | |
| download | skunky-art-1.3.tar.gz skunky-art-1.3.tar.bz2 skunky-art-1.3.zip | |
Исправление некоторых обосрамсовv1.3
Diffstat (limited to 'app/router.go')
| -rw-r--r-- | app/router.go | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/app/router.go b/app/router.go index f3c59c5..0dd2f79 100644 --- a/app/router.go +++ b/app/router.go @@ -51,7 +51,6 @@ func Router() { } path := parsepath(r.URL.Path) - // структура с функциями var skunky skunkyart skunky.Writer = w @@ -77,7 +76,7 @@ func Router() { default: skunky.ReturnHTTPError(404) case "": - skunky.ExecuteTemplate("html/index.htm", &CFG.BasePath) + skunky.ExecuteTemplate("index.htm", &CFG.BasePath) case "post": skunky.Deviation(path[2], path[3]) case "search": @@ -98,10 +97,10 @@ func Router() { skunky.About() case "stylesheet": w.Header().Add("content-type", "text/css") - io.WriteString(w, Templates["css/skunky.css"]) + io.WriteString(w, Templates["skunky.css"]) } } http.HandleFunc("/", handle) - http.ListenAndServe(CFG.Listen, nil) + try_with_exitstatus(http.ListenAndServe(CFG.Listen, nil), 1) } |
