Remove Accept-Charset header
This commit is contained in:
parent
de544a752e
commit
5133a88060
|
@ -307,7 +307,6 @@ public class ClientUtils {
|
|||
request.addHeader("Accept", format);
|
||||
request.addHeader("Content-Type", format + ";charset=" + DEFAULT_CHARSET);
|
||||
}
|
||||
request.addHeader("Accept-Charset", DEFAULT_CHARSET);
|
||||
if (headers != null) {
|
||||
for (Header header : headers) {
|
||||
request.addHeader(header);
|
||||
|
|
|
@ -263,7 +263,6 @@ public class ClientUtils {
|
|||
request.addHeader("Accept", format);
|
||||
request.addHeader("Content-Type", format + ";charset=" + DEFAULT_CHARSET);
|
||||
}
|
||||
request.addHeader("Accept-Charset", DEFAULT_CHARSET);
|
||||
if (headers != null) {
|
||||
for (Header header : headers) {
|
||||
request.addHeader(header);
|
||||
|
|
|
@ -84,7 +84,6 @@ public class FhirRequestBuilder {
|
|||
/**
|
||||
* Adds necessary headers for all REST requests.
|
||||
* <li>User-Agent : hapi-fhir-tooling-client</li>
|
||||
* <li>Accept-Charset : {@link FhirRequestBuilder#DEFAULT_CHARSET}</li>
|
||||
*
|
||||
* @param request {@link Request.Builder} to add default headers to.
|
||||
*/
|
||||
|
@ -92,7 +91,6 @@ public class FhirRequestBuilder {
|
|||
if (headers == null || !headers.names().contains("User-Agent")) {
|
||||
request.addHeader("User-Agent", "hapi-fhir-tooling-client");
|
||||
}
|
||||
request.addHeader("Accept-Charset", DEFAULT_CHARSET);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -88,7 +88,6 @@ public class FhirRequestBuilder {
|
|||
/**
|
||||
* Adds necessary headers for all REST requests.
|
||||
* <li>User-Agent : hapi-fhir-tooling-client</li>
|
||||
* <li>Accept-Charset : {@link FhirRequestBuilder#DEFAULT_CHARSET}</li>
|
||||
*
|
||||
* @param request {@link Request.Builder} to add default headers to.
|
||||
*/
|
||||
|
@ -96,7 +95,6 @@ public class FhirRequestBuilder {
|
|||
if (headers == null || !headers.names().contains("User-Agent")) {
|
||||
request.addHeader("User-Agent", "hapi-fhir-tooling-client");
|
||||
}
|
||||
request.addHeader("Accept-Charset", DEFAULT_CHARSET);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -1558,7 +1558,6 @@
|
|||
<xs:attribute name="onsubmit" type="Script"/>
|
||||
<xs:attribute name="onreset" type="Script"/>
|
||||
<xs:attribute name="accept" type="ContentTypes"/>
|
||||
<xs:attribute name="accept-charset" type="Charsets"/>
|
||||
</xs:extension>
|
||||
</xs:complexContent>
|
||||
</xs:complexType>
|
||||
|
|
|
@ -78,7 +78,6 @@ public class FhirRequestBuilder {
|
|||
/**
|
||||
* Adds necessary headers for all REST requests.
|
||||
* <li>User-Agent : hapi-fhir-tooling-client</li>
|
||||
* <li>Accept-Charset : {@link FhirRequestBuilder#DEFAULT_CHARSET}</li>
|
||||
*
|
||||
* @param request {@link Request.Builder} to add default headers to.
|
||||
*/
|
||||
|
@ -86,7 +85,6 @@ public class FhirRequestBuilder {
|
|||
if (headers == null || !headers.names().contains("User-Agent")) {
|
||||
request.addHeader("User-Agent", "hapi-fhir-tooling-client");
|
||||
}
|
||||
request.addHeader("Accept-Charset", DEFAULT_CHARSET);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -26,9 +26,6 @@ class FhirRequestBuilderTest {
|
|||
Assertions.assertEquals("hapi-fhir-tooling-client", headersMap.get("User-Agent").get(0),
|
||||
"User-Agent header not populated with expected value \"hapi-fhir-tooling-client\".");
|
||||
|
||||
Assertions.assertNotNull(headersMap.get("Accept-Charset"), "Accept-Charset header null.");
|
||||
Assertions.assertEquals(FhirRequestBuilder.DEFAULT_CHARSET, headersMap.get("Accept-Charset").get(0),
|
||||
"Accept-Charset header not populated with expected value " + FhirRequestBuilder.DEFAULT_CHARSET);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
@ -75,7 +75,6 @@ public class FhirRequestBuilder {
|
|||
/**
|
||||
* Adds necessary headers for all REST requests.
|
||||
* <li>User-Agent : hapi-fhir-tooling-client</li>
|
||||
* <li>Accept-Charset : {@link FhirRequestBuilder#DEFAULT_CHARSET}</li>
|
||||
*
|
||||
* @param request {@link Request.Builder} to add default headers to.
|
||||
*/
|
||||
|
@ -83,7 +82,6 @@ public class FhirRequestBuilder {
|
|||
if (headers == null || !headers.names().contains("User-Agent")) {
|
||||
request.addHeader("User-Agent", "hapi-fhir-tooling-client");
|
||||
}
|
||||
request.addHeader("Accept-Charset", DEFAULT_CHARSET);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -23,10 +23,6 @@ class FhirRequestBuilderTest {
|
|||
Assertions.assertNotNull(headersMap.get("User-Agent"), "User-Agent header null.");
|
||||
Assertions.assertEquals("hapi-fhir-tooling-client", headersMap.get("User-Agent").get(0),
|
||||
"User-Agent header not populated with expected value \"hapi-fhir-tooling-client\".");
|
||||
|
||||
Assertions.assertNotNull(headersMap.get("Accept-Charset"), "Accept-Charset header null.");
|
||||
Assertions.assertEquals(FhirRequestBuilder.DEFAULT_CHARSET, headersMap.get("Accept-Charset").get(0),
|
||||
"Accept-Charset header not populated with expected value " + FhirRequestBuilder.DEFAULT_CHARSET);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
Loading…
Reference in New Issue