mirror of
https://github.com/danbulant/jose
synced 2026-05-24 20:41:46 +00:00
refactor: freeze the key's x5c array
This commit is contained in:
parent
0e28282e3e
commit
94ec607d4c
1 changed files with 3 additions and 0 deletions
|
|
@ -57,6 +57,9 @@ class Key {
|
|||
throw new TypeError('`x5c` must be an array of one or more PKIX certificates when provided')
|
||||
}
|
||||
|
||||
x5c = [...x5c]
|
||||
Object.freeze(x5c)
|
||||
|
||||
x5c.forEach((cert, i) => {
|
||||
let publicKey
|
||||
try {
|
||||
|
|
|
|||
Loading…
Reference in a new issue