IDEA: fix dev server run configuration on Windows. Fix CORS issue with stack trace deobfuscator

This commit is contained in:
Alexey Andreev 2019-02-18 13:07:51 +03:00
parent 4a325a192e
commit bd00575219
2 changed files with 2 additions and 1 deletions

View File

@ -324,6 +324,7 @@ public class CodeServlet extends HttpServlet {
if (fileContent != null) { if (fileContent != null) {
resp.setStatus(HttpServletResponse.SC_OK); resp.setStatus(HttpServletResponse.SC_OK);
resp.setCharacterEncoding("UTF-8"); resp.setCharacterEncoding("UTF-8");
resp.setHeader("Access-Control-Allow-Origin", "*");
resp.setContentType("text/plain"); resp.setContentType("text/plain");
resp.getOutputStream().write(fileContent); resp.getOutputStream().write(fileContent);
resp.getOutputStream().flush(); resp.getOutputStream().flush();

View File

@ -212,7 +212,7 @@ public class DevServerRunner extends UnicastRemoteObject implements DevServerMan
arguments.add("-proxy-url"); arguments.add("-proxy-url");
arguments.add(options.proxyUrl); arguments.add(options.proxyUrl);
} }
if (options.proxyPath != null) { if (options.proxyPath != null && !options.proxyPath.isEmpty()) {
arguments.add("-proxy-path"); arguments.add("-proxy-path");
arguments.add(options.proxyPath); arguments.add(options.proxyPath);
} }