Permalink
Browse files

revert domains support

  • Loading branch information...
1 parent 85122b7 commit 14f6955985dd0b43a383ac0d0d625abdaf21d4fc @defunctzombie defunctzombie committed Apr 29, 2013
Showing with 0 additions and 14 deletions.
  1. +0 −14 bcrypt.js
View
@@ -1,13 +1,5 @@
var bindings = require('bindings')('bcrypt_lib');
-var bind_to_domain = function(cb) {
- if (process.domain) {
- cb = process.domain.bind(cb);
- }
-
- return cb;
-}
-
/// generate a salt (sync)
/// @param {Number} [rounds] number of rounds (default 10)
/// @param {Number} [seed_length] number of random bytes (default 20)
@@ -78,8 +70,6 @@ module.exports.genSalt = function(rounds, seed_length, cb) {
throw new Error('callback required for gen_salt');
}
- cb = bind_to_domain(cb);
-
return bindings.gen_salt(rounds, seed_length, cb);
};
@@ -136,8 +126,6 @@ module.exports.hash = function(data, salt, cb) {
});
}
- cb = bind_to_domain(cb);
-
return bindings.encrypt(data, salt, cb);
};
@@ -178,8 +166,6 @@ module.exports.compare = function(data, hash, cb) {
throw new Error('callback must be a function');
}
- cb = bind_to_domain(cb);
-
return bindings.compare(data, hash, cb);
};

0 comments on commit 14f6955

Please sign in to comment.