Skip to content

Commit 2f449af

Browse files
adamjmcgrathpanva
andauthored
chore: update fips check
Co-authored-by: Filip Skokan <panva.ip@gmail.com>
1 parent 84fe3ee commit 2f449af

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎lib/oaep.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ var crypto = require('crypto');
77
// this is not a FIPS valid code path.
88

99
function assertShimAllowed() {
10-
if (typeof crypto.getFips === 'function' && crypto.getFips()) {
10+
if (crypto.getFips?.()) {
1111
var err = new Error('unsupported cryptographic operation');
1212
err.code = 'ERR_XMLENC_FIPS_UNSUPPORTED';
1313
throw err;

0 commit comments

Comments
 (0)