<commit_before>package middlewares

import (
	"github.com/sirupsen/logrus"
	"github.com/urfave/negroni"
)

const httpLoggerFormat = "request processed: {{.StartTime}} | {{.Status}} | {{.Duration}} | {{.Method}} {{.Path}}"

func NewLogger(logger logrus.FieldLogger) negroni.Handler {
	middleware := negroni.NewLogger()
	middleware.SetFormat(httpLoggerFormat)
	middleware.ALogger = logger
	return middleware
}<commit_msg>Create TODO in logger middleware<commit_after>package middlewares

import (
	"github.com/sirupsen/logrus"
	"github.com/urfave/negroni"
)

const httpLoggerFormat = "request processed: {{.StartTime}} | {{.Status}} | {{.Duration}} | {{.Method}} {{.Path}}"

// TODO: Use https://github.com/meatballhat/negroni-logrus ?

func NewLogger(logger logrus.FieldLogger) negroni.Handler {
	middleware := negroni.NewLogger()
	middleware.SetFormat(httpLoggerFormat)
	middleware.ALogger = logger
	return middleware
}
{'fraction_non_alphanumeric': 0.14907508161044614, 'fraction_numerical': 0.0, 'mean_word_length': 5.7153284671532845, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4972284', 'n_tokens_mistral': 318, 'n_tokens_neox': 316, 'n_words': 57}