The Venify ACME server api returns 'application/json; utf-8' as the content header type

pull/39/head
Justin Field 2017-10-31 14:21:31 -07:00
parent d666ec091c
commit 2bf7abd1df
1 changed files with 2 additions and 2 deletions

View File

@ -213,8 +213,8 @@ public class DefaultConnection implements Connection {
assertConnectionIsOpen();
String contentType = conn.getHeaderField(CONTENT_TYPE_HEADER);
if (!("application/json".equals(contentType)
|| "application/problem+json".equals(contentType))) {
if (contentType == null || !(contentType.contains("application/json")
|| contentType.contains("application/problem+json"))) {
throw new AcmeProtocolException("Unexpected content type: " + contentType);
}