add
This commit is contained in:
@ -1,5 +1,7 @@
|
||||
package com.qiaoba.common.web.utils;
|
||||
|
||||
import cn.hutool.http.ContentType;
|
||||
import cn.hutool.http.HttpUtil;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import com.qiaoba.common.base.result.AjaxResult;
|
||||
|
||||
@ -18,7 +20,7 @@ public class ResponseUtil {
|
||||
|
||||
public static void response(HttpServletResponse response, String msg) throws IOException {
|
||||
response.setStatus(HttpServletResponse.SC_OK);
|
||||
response.setContentType("text/plain; charset=UTF-8");
|
||||
response.setContentType(ContentType.JSON.getValue());
|
||||
PrintWriter writer = response.getWriter();
|
||||
writer.write(msg);
|
||||
writer.close();
|
||||
|
Reference in New Issue
Block a user