This commit is contained in:
2017-06-17 01:25:02 +02:00
parent a9f88db566
commit 88614d412b
12 changed files with 18 additions and 18 deletions

View File

@ -11,8 +11,8 @@ import (
"github.com/aerogo/log"
)
// RequestLog logs every request into logs/request.log.
func RequestLog() aero.Middleware {
// Log middleware logs every request into logs/request.log.
func Log() aero.Middleware {
err := log.NewLog()
err.AddOutput(log.File("logs/error.log"))
err.AddOutput(os.Stderr)

View File

@ -2,8 +2,8 @@ package middleware
import "github.com/aerogo/aero"
// SaveSession saves an existing session if it has been modified.
func SaveSession() aero.Middleware {
// Session middleware saves an existing session if it has been modified.
func Session() aero.Middleware {
return func(ctx *aero.Context, next func()) {
// Handle the request first
next()