Skip to content
Snippets Groups Projects
Commit 93ca4401 authored by Dean's avatar Dean
Browse files

add status code to /upload/simple

parent f860ea7f
No related branches found
No related tags found
No related merge requests found
......@@ -356,9 +356,12 @@ func UploadPomf(associateObjectsWithUser bool, simpleResponse bool) func(http.Re
// Simple response
if simpleResponse {
for _, fResponse := range fileResponses {
w.Write([]byte(fmt.Sprintf("%s\n", fResponse.URL)))
if fResponse.Success {
w.Write([]byte(fmt.Sprintf("%s,200\n", fResponse.URL)))
} else {
w.Write([]byte(",500\n"))
}
}
} else {
render.JSON(w, r, fullResponse{Success: true, Files: fileResponses})
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment