Fixed the query for extracting path from stat

This commit is contained in:
Diptanu Choudhury
2016-01-13 13:21:03 -08:00
parent 9dced9a890
commit ee369382aa

View File

@@ -29,7 +29,7 @@ func (s *HTTPServer) FileStatRequest(resp http.ResponseWriter, req *http.Request
if allocID = strings.TrimPrefix(req.URL.Path, "/v1/client/fs/stat/"); allocID == "" {
return nil, allocIDNotPresentErr
}
if path := req.URL.Query().Get("path"); path == "" {
if path = req.URL.Query().Get("path"); path == "" {
return nil, fileNameNotPresentErr
}
return s.agent.client.FSStat(allocID, path)