diff options
-rw-r--r-- | lib/crypto.js | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/lib/crypto.js b/lib/crypto.js index ed8b7539e..90e139af3 100644 --- a/lib/crypto.js +++ b/lib/crypto.js @@ -31,10 +31,8 @@ try { var pseudoRandomBytes = binding.pseudoRandomBytes; var getCiphers = binding.getCiphers; var getHashes = binding.getHashes; - var crypto = true; } catch (e) { - - var crypto = false; + throw new Error('node.js not compiled with openssl crypto support.'); } var stream = require('stream'); @@ -62,10 +60,6 @@ function Credentials(secureProtocol, flags, context) { return new Credentials(secureProtocol, flags, context); } - if (!crypto) { - throw new Error('node.js not compiled with openssl crypto support.'); - } - if (context) { this.context = context; } else { |