Statement unnecessarily nested within else clause.

git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1728604 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Gary D. Gregory 2016-02-05 04:59:28 +00:00
parent 2b573561f8
commit cd4fc8f885
1 changed files with 6 additions and 8 deletions

View File

@ -68,9 +68,8 @@ public class ByteArrayBuilder {
buffer.flip();
newBuffer.put(buffer);
return newBuffer;
} else {
return buffer;
}
return buffer;
}
static ByteBuffer encode(
@ -186,13 +185,12 @@ public class ByteArrayBuilder {
public byte[] toByteArray() {
if (this.buffer == null) {
return new byte[] {};
} else {
this.buffer.flip();
final byte[] b = new byte[this.buffer.remaining()];
this.buffer.get(b);
this.buffer.clear();
return b;
}
this.buffer.flip();
final byte[] b = new byte[this.buffer.remaining()];
this.buffer.get(b);
this.buffer.clear();
return b;
}
public void reset() {