|
|
@@ -18,6 +18,7 @@ import cn.reghao.oss.store.util.StringUtil;
|
|
|
import cn.reghao.oss.store.util.UserContext;
|
|
|
import org.apache.commons.io.FileUtils;
|
|
|
import org.springframework.http.HttpStatus;
|
|
|
+import org.springframework.http.MediaType;
|
|
|
import org.springframework.http.ResponseEntity;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
import org.springframework.web.multipart.MultipartFile;
|
|
|
@@ -52,7 +53,7 @@ public class ObjectUploadController {
|
|
|
return WebResult.failWithMsg("not implement");
|
|
|
}
|
|
|
|
|
|
- @PostMapping(value = "/")
|
|
|
+ @PostMapping(value = "/", produces = MediaType.APPLICATION_JSON_VALUE)
|
|
|
public ResponseEntity<String> postObject(MultipartFile file, Integer channelId,
|
|
|
String client, String sha256sum, Long userId) throws Exception {
|
|
|
/* permission check */
|