Merge pull request #485 from andrewgaul/simplify-java-url-http-command-executor-service-invoke

Simplify JavaUrlHttpCommandExecutorService.invoke
This commit is contained in:
Adrian Cole 2012-03-20 10:50:07 -07:00
commit 20bfcdf789
1 changed files with 2 additions and 2 deletions

View File

@ -135,8 +135,8 @@ public class JavaUrlHttpCommandExecutorService extends BaseHttpCommandExecutorSe
headerBuilder.putAll(header, entry.getValue());
}
ImmutableMultimap<String, String> headers = headerBuilder.build();
Payload payload = in != null ? newInputStreamPayload(in) : null;
if (payload != null) {
if (in != null) {
Payload payload = newInputStreamPayload(in);
payload.getContentMetadata().setPropertiesFromHttpHeaders(headers);
builder.payload(payload);
}