Skip to content

Commit 9ed156e

Browse files
committed
Remove unnecessary Bytes.concat calls
1 parent 9f3a263 commit 9ed156e

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

webauthn-server-core/src/main/java/com/yubico/webauthn/WebAuthnCodecs.java

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,10 @@ static ByteArray ecPublicKeyToRaw(ECPublicKey key) {
6464
return new ByteArray(
6565
Bytes.concat(
6666
new byte[] {0x04},
67-
Bytes.concat(
68-
xPadding, Arrays.copyOfRange(x, Math.max(0, x.length - fieldSizeBytes), x.length)),
69-
Bytes.concat(
70-
yPadding,
71-
Arrays.copyOfRange(y, Math.max(0, y.length - fieldSizeBytes), y.length))));
67+
xPadding,
68+
Arrays.copyOfRange(x, Math.max(0, x.length - fieldSizeBytes), x.length),
69+
yPadding,
70+
Arrays.copyOfRange(y, Math.max(0, y.length - fieldSizeBytes), y.length)));
7271
}
7372

7473
static ByteArray rawEcKeyToCose(ByteArray key) {

0 commit comments

Comments
 (0)