package com.thebrokenrail.scriptcraft.core.quickjs; import java.io.PrintWriter; import java.io.StringWriter; public class JSException extends Exception { public JSException(String message) { super(message); } @SuppressWarnings("unused") public static String getStackTrace(Throwable e) { StringWriter writer = new StringWriter(); e.printStackTrace(new PrintWriter(writer)); return writer.toString(); } }