1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-08-21 18:11:09 +00:00

Add logger

This commit is contained in:
Frédéric Guillot 2017-12-15 18:55:57 -08:00
parent c6d9eb3614
commit 1d8193b892
56 changed files with 228 additions and 192 deletions

View file

@ -7,12 +7,12 @@ package core
import (
"fmt"
"io"
"log"
"mime/multipart"
"net/http"
"strconv"
"github.com/gorilla/mux"
"github.com/miniflux/miniflux/logger"
)
// Request is a thin wrapper around "http.Request".
@ -68,7 +68,7 @@ func (r *Request) IntegerParam(param string) (int64, error) {
vars := mux.Vars(r.request)
value, err := strconv.Atoi(vars[param])
if err != nil {
log.Println(err)
logger.Error("[IntegerParam] %v", err)
return 0, fmt.Errorf("%s parameter is not an integer", param)
}