mirror of https://github.com/apache/activemq.git
AMQ-4668: REST API only accepts non-form content if content type of text/xml
This commit is contained in:
parent
190da29691
commit
70e2b998d2
|
@ -341,7 +341,8 @@ public abstract class MessageServletSupport extends HttpServlet {
|
|||
protected String getPostedMessageBody(HttpServletRequest request) throws IOException {
|
||||
String answer = request.getParameter(bodyParameter);
|
||||
String contentType = request.getContentType();
|
||||
if (answer == null && contentType != null && contentType.toLowerCase().startsWith("text/xml")) {
|
||||
if (answer == null && contentType != null) {
|
||||
LOG.debug("Content-Type={}", contentType);
|
||||
// lets read the message body instead
|
||||
BufferedReader reader = request.getReader();
|
||||
StringBuffer buffer = new StringBuffer();
|
||||
|
|
Loading…
Reference in New Issue