cmd/syncthing: Remove spurious <nil> in debug output

Remove spurious gui.go:985: DEBUG: <nil> on successful call time.Parse() in getSystemLog and getSystemLogTxt.
This commit is contained in:
Peter Marquardt 2018-04-14 10:46:33 +02:00 committed by Jakob Borg
parent ea43e089d4
commit 3ef19411f9
1 changed files with 6 additions and 2 deletions

View File

@ -982,7 +982,9 @@ func (s *apiService) postSystemErrorClear(w http.ResponseWriter, r *http.Request
func (s *apiService) getSystemLog(w http.ResponseWriter, r *http.Request) {
q := r.URL.Query()
since, err := time.Parse(time.RFC3339, q.Get("since"))
l.Debugln(err)
if err != nil {
l.Debugln(err)
}
sendJSON(w, map[string][]logger.Line{
"messages": s.systemLog.Since(since),
})
@ -991,7 +993,9 @@ func (s *apiService) getSystemLog(w http.ResponseWriter, r *http.Request) {
func (s *apiService) getSystemLogTxt(w http.ResponseWriter, r *http.Request) {
q := r.URL.Query()
since, err := time.Parse(time.RFC3339, q.Get("since"))
l.Debugln(err)
if err != nil {
l.Debugln(err)
}
w.Header().Set("Content-Type", "text/plain; charset=utf-8")
for _, line := range s.systemLog.Since(since) {