1
0
mirror of https://github.com/astaxie/beego.git synced 2025-08-31 00:57:32 +00:00

Make LogAccess public

This commit is contained in:
Waleed Gadelkareem
2019-02-14 16:29:26 +01:00
parent 1942438b22
commit 8995b291a9
3 changed files with 4 additions and 4 deletions

View File

@@ -889,7 +889,7 @@ Admin:
statusCode = 200
}
logAccess(context, &startTime, statusCode)
LogAccess(context, &startTime, statusCode)
timeDur := time.Since(startTime)
context.ResponseWriter.Elapsed = timeDur
@@ -980,7 +980,7 @@ func toURL(params map[string]string) string {
return strings.TrimRight(u, "&")
}
func logAccess(ctx *beecontext.Context, startTime *time.Time, statusCode int) {
func LogAccess(ctx *beecontext.Context, startTime *time.Time, statusCode int) {
//Skip logging if AccessLogs config is false
if !BConfig.Log.AccessLogs {
return