style: lib/jwe/encrypt.js

This commit is contained in:
Filip Skokan 2020-08-05 11:47:17 +02:00
parent e0a2d57926
commit eb482a8ab8

View file

@ -190,7 +190,11 @@ class Encrypt {
let aad
if (this._aad) {
final.aad = base64url.encode(this._aad)
aad = Buffer.concat([Buffer.from(final.protected || ''), Buffer.from('.'), Buffer.from(final.aad)])
aad = Buffer.concat([
Buffer.from(final.protected || ''),
Buffer.from('.'),
Buffer.from(final.aad)
])
} else {
aad = Buffer.from(final.protected || '')
}