mirror of
https://github.com/kemko/nomad.git
synced 2026-01-06 10:25:42 +03:00
Test for errors
This commit is contained in:
@@ -123,6 +123,9 @@ func (s *HTTPServer) FileCatRequest(resp http.ResponseWriter, req *http.Request)
|
||||
}
|
||||
|
||||
r, err := fs.ReadAt(path, int64(0), fileInfo.Size)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
io.Copy(resp, r)
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user